Skip to content

fix: set TERM_PROGRAM and COLORTERM env vars for terminal identification#74

Merged
gi11es merged 1 commit intogi11es:masterfrom
trogulja:fix/set-term-program-env
Apr 6, 2026
Merged

fix: set TERM_PROGRAM and COLORTERM env vars for terminal identification#74
gi11es merged 1 commit intogi11es:masterfrom
trogulja:fix/set-term-program-env

Conversation

@trogulja
Copy link
Copy Markdown
Contributor

@trogulja trogulja commented Apr 6, 2026

Fixes #73

Summary

  • Set TERM_PROGRAM=Deckard — standard terminal identification variable, used by CLI tools to detect terminal capabilities
  • Set COLORTERM=truecolor — advertises 24-bit color support

Why

Deckard was not setting TERM_PROGRAM, so CLI tools (notably Claude Code) could not identify it as a terminal that supports the Kitty keyboard protocol. This caused Shift+Enter to submit prompts instead of inserting newlines.

When Deckard is launched from Dock/Spotlight/Raycast, no terminal identification env vars are present. When launched from another terminal (e.g. Kitty, iTerm2), their env vars leak into Deckard's process and Claude Code works correctly — confirming the issue is purely about terminal detection.

Next step

After this merges, a bug report on anthropics/claude-code is needed to add "Deckard" to their list of recognized KKP-capable terminals.

Test plan

  • All existing tests pass
  • Verified TERM_PROGRAM=Deckard and COLORTERM=truecolor appear in shell environment via env | grep -E 'TERM_PROGRAM|COLORTERM'

Deckard was not setting TERM_PROGRAM, so CLI tools (notably Claude Code)
could not identify it as a KKP-capable terminal. This caused Shift+Enter
to submit prompts instead of inserting newlines, because Claude Code only
activates Kitty keyboard protocol for recognized terminals.

Set TERM_PROGRAM=Deckard (standard terminal identification variable) and
COLORTERM=truecolor (advertises 24-bit color support).

Fixes gi11es#73

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@gi11es
Copy link
Copy Markdown
Owner

gi11es commented Apr 6, 2026

Thanks!

@gi11es gi11es merged commit 6fec56b into gi11es:master Apr 6, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Shift+Enter doesn't work in Claude tabs (terminal not identified as KKP-capable)

2 participants