Sane VIM configuration for my personal use.
These instructions are for Vim, not Neovim. Install Vim, Git, and curl first.
curl -fLo "$HOME/.vim/autoload/plug.vim" --create-dirs \
https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vimBack up any existing configuration, then download this repository's vimrc:
if [ -e "$HOME/.vimrc" ]; then
cp -p "$HOME/.vimrc" "$HOME/.vimrc.backup.$(date +%Y%m%d%H%M%S)"
fi
curl -fLo "$HOME/.vimrc" \
https://raw.githubusercontent.com/arazgray/vimsane/main/vimrcOpen Vim:
vimOn the first launch, Vim may report E185: Cannot find color scheme 'tokyonight'
because the theme is not installed yet. Press Enter to continue, then run this
command inside Vim, not in your shell:
:PlugInstallWait for installation to finish, then close and reopen Vim.
To update installed plugins later, run :PlugUpdate inside Vim.
If Vim reports E117: Unknown function: plug#begin or
E492: Not an editor command: Plug, check that vim-plug was installed at
~/.vim/autoload/plug.vim. The Neovim path
~/.local/share/nvim/site/autoload/plug.vim is not loaded by Vim.
: Commands
i Insert
y Copy (yank!), yy Copy whole line
d Cut, dd Cut whole line
p Paste
u Undo
$ Go to End of line, A go to end of line and insert
G Go to end of doc, gg Move to begining
ESC and v Select, V for line selection
qa Close all and exit
ESC+NUM Switch Tabs
Ctrl+t Open tree
Ctrl+ww Switch to Editor from Tree
Ctrl+p Quick Open
/KEYWORD Search
%s/KEYWORD/REPLACE-WITH/gc Search and Replace (all, confirm before)
