Skip to content

Commit

Permalink
Merge branch 'develop' of https://github.com/agkozak/agkozak-zsh-prompt
Browse files Browse the repository at this point in the history
… into develop
  • Loading branch information
agkozak committed Aug 16, 2018
2 parents e6eb266 + 6f95627 commit 3d2c6d2
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -122,11 +122,12 @@ If you would like to display a different number of directory elements, set the e

![AGKOZAK_PROMPT_DIRTRIM](img/AGKOZAK_PROMPT_DIRTRIM.png)

By default, [static named directories created with `hash -d`](http://zsh.sourceforge.net/Doc/Release/Expansion.html#Static-named-directories) will be displayed in the prompt just like any others. If you use them extensively, though, you may opt to set `AGKOZAK_NAMED_DIRS=1`. The prompt will then use the named directories as base directories for its path. For example, if you execute
By default, [static named directories created with `hash -d`](http://zsh.sourceforge.net/Doc/Release/Expansion.html#Static-named-directories) will be used as base directories in the path the prompt displays. For example,
if you have executed

hash -d wp-content=/var/www/html/wp-content

then `/var/www/html/wp-content` will appear in the prompt as `~wp-content`, and `/var/www/html/wp-content/plugins/redirection/actions` will be represented as `~wp-content/.../redirection/actions`.
then `/var/www/html/wp-content` will appear in the prompt as `wp-content`, and `/var/www/html/wp-content/plugins/redirection/actions` will be represented as `~wp-content/.../redirection/actions`. If you prefer to have named directories displayed just like any others, set `AGKOZAK_NAMED_DIRS=0`.

## Git Branch and Status

Expand Down
5 changes: 3 additions & 2 deletions agkozak-zsh-prompt.plugin.zsh
Original file line number Diff line number Diff line change
Expand Up @@ -129,8 +129,9 @@ _agkozak_is_ssh() {
#
# ~/.../polyglot/img
#
# If AGKOZAK_NAMED_DIRS is set to 1, ZSH named directories
# will be displayed using their aliases in the prompt.
# Named directories will by default be displayed using their
# aliases in the prompt. Set AGKOZAK_NAMED_DIRS=0 to have
# them displayed just like any other directory.
#
# Arguments:
# $1 Number of directory elements to display (default: 2)
Expand Down

0 comments on commit 3d2c6d2

Please sign in to comment.