diff options
author | Karel Kočí <cynerd@email.cz> | 2024-02-28 09:28:56 +0100 |
---|---|---|
committer | Karel Kočí <cynerd@email.cz> | 2024-02-28 09:29:27 +0100 |
commit | 8694e74b2129d432728c0802bf1cfaf4895a6fcf (patch) | |
tree | 06c9510fc5964638b8304acd6faafa979a9744c2 | |
parent | 14176667ad9008aab2a392c9b306dd4a8fac9ac0 (diff) | |
download | shellrc-8694e74b2129d432728c0802bf1cfaf4895a6fcf.tar.gz shellrc-8694e74b2129d432728c0802bf1cfaf4895a6fcf.tar.bz2 shellrc-8694e74b2129d432728c0802bf1cfaf4895a6fcf.zip |
alias: support both vim as well as nvim
Neovim doesn't compile on armv7l and this I will just use vim on
embedded devices.
-rw-r--r-- | shellrc.d/alias | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/shellrc.d/alias b/shellrc.d/alias index 2f88e80..c84c83a 100644 --- a/shellrc.d/alias +++ b/shellrc.d/alias @@ -11,7 +11,11 @@ alias cgdb='cgdb -q' alias octave='octave-cli -q' alias ssh='TERM="xterm-256color" ssh' alias gst='git status' -alias v='nvim' +if command -v nvim >/dev/null; then + alias v='nvim' +else + alias v='vim' +fi alias watch='watch -n 1 -c -t -d' alias rej='find -name \*.rej' alias orig='find -name \*.orig' |