My Javascript / Typescript / Angular based configuration for neovim. Works on ubuntu and manjaro. I usually run neovim within tmux.
cd ~/.config && git clone https://github.com/ticklepoke/nvim.git
-
In order to initialize the files, you need to source them. However, the current vim config files are setting various plugging settings even though you have not installed them. This is kind of a catch-22. One way around is to first comment out the plugin configs in
init.vim
, source the file, and then uncomment the plugin configs.- Comment out the following in
init.vim
:
.... call plug#end() source ~/.config/nvim/general.vim "source ~/.config/nvim/keybindings.vim <-- comment all these out "source ~/.config/nvim/coc.vim "source ~/.config/nvim/nerdtree.vim "source ~/.config/nvim/nerdcommenter.vim "source ~/.config/nvim/airline.vim "source ~/.config/nvim/fzf.vim "source ~/.config/nvim/vimrooter.vim <-- until here
- Save the
init.vim
file (note, any code block with a preceding:
is meant to be ran from within the nvim editor):
:w
- Comment out the following in
-
Within the vim editor, source the
init.vim
file::so %
-
Uncomment the sources from the first step, save the
init.vim
file again and source it:.... call plug#end() source ~/.config/nvim/general.vim source ~/.config/nvim/keybindings.vim <-- uncomment all these out source ~/.config/nvim/coc.vim source ~/.config/nvim/nerdtree.vim source ~/.config/nvim/nerdcommenter.vim source ~/.config/nvim/airline.vim source ~/.config/nvim/fzf.vim source ~/.config/nvim/vimrooter.vim <-- until here
then
:w
and
:so %
-
Finally, install the plugins:
:PlugInstall
Code completion is mostly handled by coc.
```
:CocInstall coc-angular coc-css coc-git coc-html coc-json coc-markdownlint coc-pairs coc-prettier coc-sh coc-snippets coc-tsserver
```
- Resize:
alt - h / j / k / l
- Change buffer:
tab / shift-tab
- Close buffer:
\-w
- List buffers:
\-b
- Trigger suggestions:
ctrl-space
- Go to definition:
F12
- Show documentation:
K
- Toggle nerdtree:
Ctrl-n
- Find file:
Ctrl-p
- Find text:
Ctrl-f
- Git status:
\gs
- Git stage:
s
apply on specific files within git status menu - Git unstage:
u
apply on specific files within git status menu - Git commit:
cc
apply on staged files - Git push:
-
apply on commit lines