diff options
author | June McEnroe <june@causal.agency> | 2018-08-17 21:54:53 -0400 |
---|---|---|
committer | June McEnroe <june@causal.agency> | 2018-08-17 21:54:53 -0400 |
commit | 4d44bff605c600dbc032cb02fea48c75989aeb7a (patch) | |
tree | 9a153d2f1ae7ae5b8155ebce934b766226d1edd7 /home | |
parent | Add gitea2mastodon CGI script (diff) | |
download | src-4d44bff605c600dbc032cb02fea48c75989aeb7a.tar.gz src-4d44bff605c600dbc032cb02fea48c75989aeb7a.zip |
Add vim mapping to add a #include
Unfortunately as far as I know I can't have it automatically sort them after I hit escape.
Diffstat (limited to '')
-rw-r--r-- | home/.config/nvim/init.vim | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/home/.config/nvim/init.vim b/home/.config/nvim/init.vim index a3e8bb93..3651af62 100644 --- a/home/.config/nvim/init.vim +++ b/home/.config/nvim/init.vim @@ -26,5 +26,6 @@ tmap <C-w> <C-\><C-n><C-w> let g:clipboard = {'copy':{'+':'pbcopy'},'paste':{'+':'pbpaste'}} nmap <leader>h :0/^#include </,$?^#include <?sort<CR>:nohlsearch<CR> +nmap <leader>a ?^#include <<CR>:nohlsearch<CR>o#include < nmap <leader>u :0/^use/,$?^use?sort<CR>:nohlsearch<CR> nmap <leader>c :0/extern crate/,$?extern crate?sort<CR>:nohlsearch<CR> |