projects
/
grml-etc-core.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
527ab11
)
zshrc: check for empty DONTSETRPROMPT and NOTITLE
author
Michael Prokop
<mika@grml.org>
Sat, 26 Nov 2011 15:04:35 +0000
(16:04 +0100)
committer
Michael Prokop
<mika@grml.org>
Sat, 26 Nov 2011 15:04:35 +0000
(16:04 +0100)
etc/zsh/zshrc
patch
|
blob
|
history
diff --git
a/etc/zsh/zshrc
b/etc/zsh/zshrc
index
47ec759
..
0f6c36f
100644
(file)
--- a/
etc/zsh/zshrc
+++ b/
etc/zsh/zshrc
@@
-1325,7
+1325,7
@@
is4 && [[ $NOPRECMD -eq 0 ]] && precmd () {
fi
fi
# just use DONTSETRPROMPT=1 to be able to overwrite RPROMPT
fi
fi
# just use DONTSETRPROMPT=1 to be able to overwrite RPROMPT
- if [[ $
DONTSETRPROMPT
-eq 0 ]] ; then
+ if [[ $
{DONTSETRPROMPT:-}
-eq 0 ]] ; then
if [[ $BATTERY -gt 0 ]] ; then
# update battery (dropped into $PERCENT) information
battery
if [[ $BATTERY -gt 0 ]] ; then
# update battery (dropped into $PERCENT) information
battery
@@
-1336,7
+1336,7
@@
is4 && [[ $NOPRECMD -eq 0 ]] && precmd () {
fi
# adjust title of xterm
# see http://www.faqs.org/docs/Linux-mini/Xterm-Title.html
fi
# adjust title of xterm
# see http://www.faqs.org/docs/Linux-mini/Xterm-Title.html
- [[ ${NOTITLE} -gt 0 ]] && return 0
+ [[ ${NOTITLE
:-
} -gt 0 ]] && return 0
case $TERM in
(xterm*|rxvt*)
set_title ${(%):-"%n@%m: %~"}
case $TERM in
(xterm*|rxvt*)
set_title ${(%):-"%n@%m: %~"}