https://github.com/neovim/neovim/releases
curl -sLf https://spacevim.org/install.sh | bash
Shortcuts can be put in the myspacevim#before function in ~/.Spacevim.d/autoload/myspacevim.vim file.
nmap <c-h> <c-w>h
nmap <c-l> <c-w>l
nmap <c-k> <c-w>k
nmap <c-j> <c-w>j
Search word ander cursor in project
SPACE + s + a + P
Clear search results
SPACE + s + c
In init.toml:
[[options]]
bootstrap_after = "myconfig#after"
In ~/.Spacevim.d/autoload/myspacevim.vim
function! myspacevim#before() abort
...some config logic
endfunction
To create a custom menu, for example Coc commands
- create
myspacevim.vimfile in.Spacevim.d/autoload - add a
beforefunciton that initialize the custom menu. - load the funciton in the
init.tml
function! myspacevim#before() abort
call SpaceVim#custom#SPCGroupName(['k'], '+Coc')
call SpaceVim#custom#SPC('nore', ['k', 'j'], ":call CocAction('jumpDefinition')", 'jump to definition', 1)
call SpaceVim#custom#SPC('nore', ['k', 'f'], ':CocFix', 'autofix suggestion', 1)
endfunction
On a specific file type, entering command :NeoSnippetEdit. It will open an editor in the default location for a snippets file for the specific file type.
https://github.com/honza/vim-snippets/blob/master/UltiSnips/html.snippets
Need to install silver searhcer independently.
https://github.com/ggreer/the_silver_searcher
apt-get install silversearcher-ag
https://github.com/neovim/neovim/issues/7945#issuecomment-361970165
sudo apt install xsel
To copy to clipboard, yank to clipboard buffer. + y.
Need to install ts-node, typescript
npm i -g ts-node typescript
Need to install yats maybe.
wsdjeg/SpaceVim#3221 (comment)
[[custom_plugins]] # causes errors with neoformat
name = "HerringtonDarkholme/yats.vim"
merge = 0
Need to install coc tsserver maybe.
https://github.com/neoclide/coc-tsserver
:CocInstall coc-tsserver
Using language server, the + l does not show many options, but coc commands works. They can be configured as shortcuts.
CocFix autofix suggestions (ex. imports)
CocDiagnostics show language errors.
[[layers]]
name = 'lsp'
filetypes = [
'typescript',
]