+# -*- mode: sh -*-
typeset -Ag abbreviations
abbreviations=(
'...' '../..'
'....' '../../..'
'BG' '& exit'
- 'WC' '| wc'
+# WC is the alias for working tree for the --git-export option
+# 'WC' '| wc'
'GR' '|& grep '
'HD' '| head'
'HL' ' --help |& less -r'
magic-abbrev-expand() {
local MATCH
- LBUFFER=${LBUFFER%%(#m)[_a-zA-Z0-9]#}
+ LBUFFER=${LBUFFER%%(#m)[-_a-zA-Z0-9]#}
LBUFFER+=${abbreviations[$MATCH]:-$MATCH}
zle self-insert
}