diff --git a/.config/zsh/6-base b/.config/zsh/6-base index 4711f6d..e702ab1 100644 --- a/.config/zsh/6-base +++ b/.config/zsh/6-base @@ -8,7 +8,7 @@ if [[ "$(uname -s)" == "Linux" ]]; then fi # Show the top 5 commands used in recent history -alias historysummary="history | awk '{a[\$2]++} END{for(i in a){printf \"%5d\t%s\n\",a[i],i}}' | sort -rn | head" +alias zhtop="history | awk '{a[\$2]++} END{for(i in a){printf \"%5d\t%s\n\",a[i],i}}' | sort -rn | head" # Display timestamped recent command history alias zh="fc -l -d -D" @@ -20,3 +20,5 @@ alias ..="cd .." # overwritten by enhancd config in .zshrc.d/ alias ...="cd ../.." alias ~="cd ~" +# make v call vim +alias v="vim" diff --git a/.config/zsh/6-nvim-to-vim-if-installed b/.config/zsh/6-nvim-to-vim-if-installed new file mode 100644 index 0000000..1956d14 --- /dev/null +++ b/.config/zsh/6-nvim-to-vim-if-installed @@ -0,0 +1,4 @@ +#!/bin/sh + +# Check for existence of nvim command. If found, substitute vim with it. +type nvim >/dev/null 2>&1 && alias vim=nvim