dankamongmen / notcurses

blingful character graphics/TUI library. definitely not curses.
https://nick-black.com/dankwiki/index.php/Notcurses
Other
3.43k stars 113 forks source link

Unable to change `ITerm2`'s `Report Terminal Type` to recommended option `iterm2` #2715

Open kdheepak opened 1 year ago

kdheepak commented 1 year ago

Please include the following data:

COLORTERM=truecolor
ITERM_PROFILE=Default
ITERM_SESSION_ID=w0t4p1:8722C05F-6AAC-4038-99A5-FCE98572170C
LANG=en_US.UTF-8
LC_TERMINAL=iTerm2
LC_TERMINAL_VERSION=3.4.19
TERM=xterm-256color
TERM_PROGRAM=iTerm.app
TERM_PROGRAM_VERSION=3.4.19
TERM_SESSION_ID=w0t4p1:8722C05F-6AAC-4038-99A5-FCE98572170C
$ notcurses-demo --version
notcurses-demo version 3.0.9
ITerm2 Build 3.4.19

When I drop down the options for Report Terminal Type I don't see an option to set it to iterm2.

image

In the documentation it seems like it is recommended to being set as iterm2

https://github.com/dankamongmen/notcurses/blob/32eba71d312d4d783feb7b4244cdc425de481c86/TERMINALS.md?plain=1#L172-L181

https://github.com/dankamongmen/notcurses/blob/32eba71d312d4d783feb7b4244cdc425de481c86/TERMINALS.md#iterm2

Is the recommendation to type it in regardless?

dankamongmen commented 1 year ago
f002cd3e4c TERMINALS.md (nick black 2021-10-20 03:49:09 -0400 173) 
f002cd3e4c TERMINALS.md (nick black 2021-10-20 03:49:09 -0400 174) You're recommented to change "Report terminal type" to `iterm2`.
f002cd3e4c TERMINALS.md (nick black 2021-10-20 03:49:09 -0400 175) 

hrmmm. i definitely wrote this. the question is whether i actually knew what i was talking about when i wrote it. i am no user of iterm. let me see what we do with this information, if anything...

dankamongmen commented 1 year ago

looking at src/lib/in.c, it appears we recognize TERMINAL_ITERM based off an XTVERSION response.

terminfo does have an iterm2 (and iterm) entry, pointing to iTerm2.app and iTerm.app respectively:

lrwxrwxrwx 1 root root    9 2023-01-25 15:21 iterm -> iTerm.app
lrwxrwxrwx 1 root root   10 2023-01-25 15:21 iterm2 -> iTerm2.app
-rw-r--r-- 1 root root 2545 2023-01-25 15:21 iTerm2.app
-rw-r--r-- 1 root root 2602 2023-01-25 15:21 iterm2-direct
-rw-r--r-- 1 root root 1857 2023-01-25 15:21 iTerm.app

is it even possible to type it in in that widget?

when you run notcurses-info, does it definitely recognize iterm2? can you give me a screenshot or a cut-and-paste?

thanks!

kdheepak commented 1 year ago

kdheepak commented 1 year ago

It looks like it is possible to type in that widget btw.

I restarted the terminal after typing that in and I think I’m seeing no difference. So that’s good I guess?