support iTerm2 images

This commit is contained in:
booleanmaybe 2026-03-10 20:12:16 -04:00
parent 2b0d3c9544
commit a30bb461da
3 changed files with 11 additions and 3 deletions

View file

@ -1,5 +1,12 @@
# tiki
UPDATE:
Now support images in Kitty-compatible terminals (iTerm2, Kitty, WezTerm, Ghostty)
![Intro](assets/images.gif)
`tiki` is a simple and lightweight way to keep your tasks, prompts, documents, ideas, scratchpads in your project **git** repo
![Intro](assets/intro.png)
@ -11,7 +18,7 @@ documentation, brainstorming ideas, incomplete implementations, AI prompts and p
Stick them in your repo. Keep around for as long as you need. Find them back in **git** history. Make issues out of them
and take them through an agile lifecycle. `tiki` helps you save and organize these files:
- Standalone **Markdown viewer** - view and edit Markdown files, navigate to local/external/GitHub/GitLab links, edit and save
- Standalone **Markdown viewer** - view and edit Markdown files, navigate to local/external/GitHub/GitLab links, image display
- Keep, search, view and version Markdown files in the **git repo**
- **Wiki-style** documentation with multiple entry points
- Keep a **to-do list** with priorities, status, assignee and size

BIN
assets/images.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.5 MiB

View file

@ -5,7 +5,7 @@ import "os"
// SupportsKittyGraphics returns true if the terminal supports the Kitty
// graphics protocol (Unicode placeholders). Detection is env-var based:
// Kitty sets KITTY_WINDOW_ID, WezTerm sets WEZTERM_EXECUTABLE, Ghostty
// sets GHOSTTY_RESOURCES_DIR, and Konsole identifies via TERM_PROGRAM.
// sets GHOSTTY_RESOURCES_DIR, and iTerm2/Konsole identify via TERM_PROGRAM.
func SupportsKittyGraphics() bool {
if os.Getenv("KITTY_WINDOW_ID") != "" {
return true
@ -16,7 +16,8 @@ func SupportsKittyGraphics() bool {
if os.Getenv("GHOSTTY_RESOURCES_DIR") != "" {
return true
}
if os.Getenv("TERM_PROGRAM") == "Konsole" {
switch os.Getenv("TERM_PROGRAM") {
case "iTerm.app", "Konsole":
return true
}
return false