X-Git-Url: http://git.grml.org/?a=blobdiff_plain;f=etc%2Fzsh%2Fzshrc;h=681d1d4e7fb2d156b496c3cf1e22aa29aa05f912;hb=e7b6b7eabcf585a92aaaa1c8da7f694b7a49f3ab;hp=f78f92784822d2abc612705793b1400b90daa4ed;hpb=2c8ba395a8bddb57300892c1ac27ff6036e493e9;p=grml-etc-core.git diff --git a/etc/zsh/zshrc b/etc/zsh/zshrc index f78f927..681d1d4 100644 --- a/etc/zsh/zshrc +++ b/etc/zsh/zshrc @@ -2436,6 +2436,9 @@ grmlcomp() { zstyle ':completion:*:manuals.*' insert-sections true zstyle ':completion:*:man:*' menu yes select + # provide .. as a completion + zstyle ':completion:*' special-dirs .. + # run rehash on completion so new installed program are found automatically: _force_rehash() { (( CURRENT == 1 )) && rehash @@ -3837,16 +3840,21 @@ mkmaildir() { mkdir -p ${root}/${subdir}/{cur,new,tmp} } -# xtrename() rename xterm from within GNU-screen +#f5# Change the xterm title from within GNU-screen xtrename() { - if [[ -z ${DISPLAY} ]] ; then - printf 'xtrename only makes sense in X11.\n' - return 1 + if [[ ${1} != "-f" ]] ; then + if [[ -z ${DISPLAY} ]] ; then + printf 'xtrename only makes sense in X11.\n' + return 1 + fi + else + shift fi if [[ -z ${1} ]] ; then - printf 'usage: xtrename() "title for xterm"\n' + printf 'usage: xtrename [-f] "title for xterm"\n' printf ' renames the title of xterm from _within_ screen.\n' - printf ' Also works without screen.\n' + printf ' also works without screen.\n' + printf ' will not work if DISPLAY is unset, use -f to override.\n' return 0 fi print -n "\eP\e]0;${1}\C-G\e\\"