diff options
| author | Aaron LI <aly@aaronly.me> | 2017-11-29 10:21:55 +0800 |
|---|---|---|
| committer | Aaron LI <aly@aaronly.me> | 2017-11-29 10:21:55 +0800 |
| commit | 2130263b53febd073c44fdb9336227606b498753 (patch) | |
| tree | 0dbe58ba9cece14c9451f65e987cc765e576a572 /_zsh | |
| parent | ee1b32c42dabc1b66926083e2aa6328b6831b5bd (diff) | |
| download | dotfiles-2130263b53febd073c44fdb9336227606b498753.tar.bz2 | |
zsh/prompt: explain more about gitpwd()
Diffstat (limited to '_zsh')
| -rw-r--r-- | _zsh/30-prompt.zsh | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/_zsh/30-prompt.zsh b/_zsh/30-prompt.zsh index bd821d1..a4b5323 100644 --- a/_zsh/30-prompt.zsh +++ b/_zsh/30-prompt.zsh @@ -5,7 +5,10 @@ # -# gitpwd - print %~, limited to $NDIR segments, with inline git branch +# gitpwd - format the current path with inline git branch for the +# prompt; the current path is limited to $NDIR segments, +# meanwhile long segments are shortened to be +# '<prefix>…<suffix>'. NDIRS=3 function gitpwd() { local -a segs splitprefix |
