Skip to content

Instantly share code, notes, and snippets.

View jakubsindelar's full-sized avatar

Jakub Šindelář jakubsindelar

View GitHub Profile
@jakubsindelar
jakubsindelar / set-title-tab.zsh
Created March 24, 2017 08:03 — forked from capotej/set-title-tab.zsh
sets title tab intelligently in zsh/iterm2
#!/bin/zsh -f
# This is the successor to settab and settitle functions (as well as the chpwd function).
# It avoids the explicit definition and use of special functions such as
# chpwd, precmd, preexec, instead setting appropriate arrays. This is to prevent conflicts
# with user's prompt functions and so forth.
# This is designed to put by default the computer name and whole directory path
# into the title bar (and if availble) the $PWD and penultimate directory
# in the tab. Also enables transient display of a running command (eg vim).