diff --git a/bash/.bashrc b/bash/.bashrc index 912d510..420f9f0 100644 --- a/bash/.bashrc +++ b/bash/.bashrc @@ -16,6 +16,9 @@ export PATH=$PATH:~/.local/bin alias dog='cat' alias rr='curl -s -L https://raw.githubusercontent.com/keroserene/rickrollrc/master/roll.sh | bash' #rickroll +#alias vim to nvim +alias vim='nvim' + #shutdown and reboot alias sn='shutdown now' alias rb='reboot' @@ -148,4 +151,6 @@ ex () mkcd() { mkdir "$@"&&cd "$@";} # "cdls" to cd and ls in one go cdls() { cd "$@"&&ls;} +#cdvim to cd into the directory of a file and open the file in vim +cdvim(){ cd "$(dirname "$@")" && vim "$(basename "$@")";} # <<< cd shortcuts <<<