Skip to content

Commit

Permalink
feat(widgets): follow zsh naming conventions
Browse files Browse the repository at this point in the history
  • Loading branch information
olets committed Jan 19, 2020
1 parent 2bef430 commit 81c000e
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions zsh-abbr.zsh
Original file line number Diff line number Diff line change
Expand Up @@ -42,20 +42,20 @@ function _zsh_abbr_init() {

function _zsh_abbr_bind_widgets() {
# spacebar expands abbreviations
zle -N _zsh_expand_space
bindkey " " _zsh_expand_space
zle -N _zsh_abbr_expand_space
bindkey " " _zsh_abbr_expand_space

# control-spacebar is a normal space
bindkey "^ " magic-space

# when running an incremental search,
# spacebar behaves normally and control-space expands abbreviations
bindkey -M isearch "^ " _zsh_expand_space
bindkey -M isearch "^ " _zsh_abbr_expand_space
bindkey -M isearch " " magic-space

# enter key expands and accepts abbreviations
zle -N _zsh_expand_accept
bindkey "^M" _zsh_expand_accept
zle -N _zsh_abbr_expand_accept
bindkey "^M" _zsh_abbr_expand_accept
}


Expand Down

0 comments on commit 81c000e

Please sign in to comment.