ZSH: Print separator between commands
This commit is contained in:
parent
3b2dec87f8
commit
db87573875
1 changed files with 12 additions and 1 deletions
13
.zshrc
13
.zshrc
|
@ -22,6 +22,16 @@ function env()
|
||||||
exec /usr/bin/env "$@" | grep -v ^LESS_TERMCAP_
|
exec /usr/bin/env "$@" | grep -v ^LESS_TERMCAP_
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function line()
|
||||||
|
{
|
||||||
|
let width=`expr $COLUMNS - ${#1} - 2`
|
||||||
|
for i in {1..$width}
|
||||||
|
do
|
||||||
|
echo -n \\x2d
|
||||||
|
done
|
||||||
|
echo " $1"
|
||||||
|
}
|
||||||
|
|
||||||
# Initialize colors.
|
# Initialize colors.
|
||||||
autoload -U colors
|
autoload -U colors
|
||||||
colors
|
colors
|
||||||
|
@ -42,7 +52,8 @@ chpwd_functions+='chpwd_update_git_vars'
|
||||||
chpwd_functions+='chpwd_show_todo'
|
chpwd_functions+='chpwd_show_todo'
|
||||||
|
|
||||||
# Set the prompt.
|
# Set the prompt.
|
||||||
PROMPT='(%{${fg[magenta]}%}%m%{${fg[default]}%} %{${fg[cyan]}%}%B%~%b%{${fg[default]}%}) %(?.%{${fg[green]}%}O.%{${fg[red]}%}X)%{${fg[default]}%} %# '
|
PROMPT='%{${fg[black]}%}$(line "$(date +%d-%m-%Y\ %H:%M)")%{${fg[default]}%}
|
||||||
|
(%{${fg[magenta]}%}%m%{${fg[default]}%} %{${fg[cyan]}%}%B%~%b%{${fg[default]}%}) %(?.%{${fg[green]}%}O.%{${fg[red]}%}X)%{${fg[default]}%} %# '
|
||||||
RPROMPT='$(prompt_git_info)%{${fg[default]}%}'
|
RPROMPT='$(prompt_git_info)%{${fg[default]}%}'
|
||||||
|
|
||||||
# Set terminal name to current runnign application
|
# Set terminal name to current runnign application
|
||||||
|
|
Loading…
Reference in a new issue