This is the version 5f55087db7f0f8939cf7a2f1 from 2020-09-06 16:04:13 comment: 'clipboard'
nvim ed
...a vim-based text editor!
basic usage ed
leave any mode by ESC ...go into "normal mode"
command mode ed
From general mode type :Some commands (enter ↵):
:q quit :q! quit (ignore changes) :wq save + quit :w save :!XXX run a shell command XXX :r FFF read a file and insert at cursor :r!XXX run a shell command and insert the output
TAB can display auto complete
normal mode ed
/XXX↵ search n next i edit mode dd delete line d10↵ delete 10 lines yy copy line y10↵ copy 10 lines p paste after current line P paste before current line u undo Ctrl+r redo
insert mode ed
Almost like a regular text editor...
visual mode ed
Enter via v, or ...
special stuff ed
mouse ed
- enable
set mouse=a
Now, selecting starts visual mode
- disable
set mouse=
system clipboard ed
install xclipvisual mod select
"+y↵ copy
plugin managers ed
vim-plug ed
- install vim-plug
sh -c 'curl -fLo "${XDG_DATA_HOME:-$HOME/.local/share}"/nvim/site/autoload/plug.vim --create-dirs \
https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim'- install a plugin
- edit .config/nvim/init.vim
call plug#begin() Plug 'itchyny/lightline.vim' Plug 'preservim/nerdtree' Plug 'lervag/vimtex' Plug 'SirVer/ultisnips' call plug#end() ...
- inside nvim
ESC:PlugInstall
this will download and install all requested plugins
vim8 internal ed
...
plugins ed
nerd tree ed
- install nerdtree
git clone https://github.com/preservim/nerdtree.git ~/.vim/pack/vendor/start/nerdtree vim -u NONE -c "helptags ~/.vim/pack/vendor/start/nerdtree/doc" -c q
- edit .config/nvim/init.vim
call plug#begin()
Plug 'preservim/nerdtree'
call plug#end()
autocmd StdinReadPre * let s:std_in=1
autocmd VimEnter * if argc() == 0 && !exists("s:std_in") | NERDTree | endifESC:PlugInstall
vimtex ed
Plug 'lervag/vimtex'
Categories: Computer