This is a minimal zsh theme with colors adopted from the robbyrussell's theme. Displays current working directory and git information1 in the prompt.
If you're interested in this theme, then you might also want to check out my zim configurations.
Several shell variables could control this theme's behavior:
DEFAULT_USER
: If$USER
is same to$DEFAULT_USER
, username would not appear in the rprompt; otherwise it will be displayed in this format:${USER}@${SHORT_HOST}
. I've found this setting quite useful for whom might switch between multiple users (e.g., system admins). This must be set before sourcing the theme.MIN_COLUMNS
: If the length of (shell expanded) current directory is greater than$COLUMNS - $MIN_COLUMNS
, current working directory in the prompt will be truncated to the last two path components. If$MIN_COLUMNS
is not set, it is default to30
.
Footnotes
-
Implemented with zsh's
vsc_info
function. ↩