X-Git-Url: http://git.grml.org/?a=blobdiff_plain;f=etc%2Fzsh%2Fzshrc;h=0b82cb3300004853a06774c1b50fb46b83d4eeea;hb=dc4eb5bb4a81c8dbe312bd0f79721fe3a3dd6af8;hp=a8b887a77bd4232e285fd9711f32df7db1d23801;hpb=1e010be0f3a7365ee1539d0858ef36092a834869;p=grml-etc-core.git diff --git a/etc/zsh/zshrc b/etc/zsh/zshrc index a8b887a..0b82cb3 100644 --- a/etc/zsh/zshrc +++ b/etc/zsh/zshrc @@ -635,6 +635,10 @@ zle -N slash-backward-kill-word #k# Kill everything in a word up to its last \kbd{/} bindkey '\ev' slash-backward-kill-word +#k# Kill everything in a word up to its last \kbd{/} +bindkey '\e^h' slash-backward-kill-word +#k# Kill everything in a word up to its last \kbd{/} +bindkey '\e^?' slash-backward-kill-word # use the new *-pattern-* widgets for incremental history search if is439 ; then @@ -3075,14 +3079,14 @@ exit 0; ssl_hashes=( sha512 sha256 sha1 md5 ) for sh in ${ssl_hashes}; do - ssl-cert-${sh}() { + eval 'ssl-cert-'${sh}'() { emulate -L zsh if [[ -z $1 ]] ; then - printf 'usage: %s \n' "ssh-cert-${sh}" + printf '\''usage: %s \n'\'' "ssh-cert-'${sh}'" return 1 fi - openssl x509 -noout -fingerprint -${sh} -in $1 - } + openssl x509 -noout -fingerprint -'${sh}' -in $1 + }' done; unset sh ssl-cert-fingerprints() { @@ -3120,6 +3124,9 @@ if [[ -r ~/.important_commands ]] ; then fi # }}} +# load the lookup subsystem if it's available on the system +zrcautoload lookupinit && lookupinit + #:grep:marker:for:mika: :-) ### non-root (EUID != 0) code below ### @@ -3129,8 +3136,6 @@ if (( GRML_ALWAYS_LOAD_ALL == 0 )) && (( $EUID == 0 )) ; then return 0 fi -zrcautoload lookupinit && lookupinit - # variables {{{ # set terminal property (used e.g. by msgid-chooser) @@ -3546,29 +3551,6 @@ alias GREP='grep -i --color=auto' #f5# Watch manpages in a stretched style man2() { PAGER='dash -c "sed G | /usr/bin/less"' command man "$@" ; } -# d():Copyright 2005 Nikolai Weibull -# note: option AUTO_PUSHD has to be set -#f5# Jump between directories -d() { - emulate -L zsh - autoload -U colors - local color=$fg_bold[blue] - integer i=0 - dirs -p | while read dir; do - local num="${$(printf "%-4d " $i)/ /.}" - printf " %s $color%s$reset_color\n" $num $dir - (( i++ )) - done - integer dir=-1 - read -r 'dir?Jump to directory: ' || return - (( dir == -1 )) && return - if (( dir < 0 || dir >= i )); then - echo d: no such directory stack entry: $dir - return 1 - fi - cd ~$dir -} - # usage example: 'lcheck strcpy' #f5# Find out which libs define a symbol lcheck() {