I am using a oh-my-zsh shell in an Apple terminal (2.11) in full screen, and by default the name of the tabs is the name of the program being run (eg. vim).
Is there an easy way to set the title of the individual terminal tabs to the filename currently opened with vim?
The terminal window title is already set, but not visible in full screen mode. What I'm looking for is to get at a glance the title of all terminal tabs where vim is opened.
CodePudding user response:
The solution seems to use vim script shared in https://stackoverflow.com/a/48975505/4756084 sets the title dynamically based on what file is currently being viewed, which your Terminal Preferences > Tab > "Active process name" with "Arguments" doesn't allow (it would only display the name of the file opened when typing vim file.ext, ignoring any :e file2.txt, switching between vim panes, etc.)
With oh-my-zsh, uncommenting DISABLE_AUTO_TITLE="true" in ~/.zshrc might help, as suggested in https://superuser.com/questions/292652/change-iterm2-window-and-tab-titles-in-zsh, although it seems optional after the step above.

