diff options
author | Tom Ryder <tom@sanctum.geek.nz> | 2017-11-04 00:31:04 +1300 |
---|---|---|
committer | Tom Ryder <tom@sanctum.geek.nz> | 2017-11-04 00:36:46 +1300 |
commit | 703c63113d6e089136259ab077422b51f636309a (patch) | |
tree | a15fc24d18ebfa8790024036fc7615792b124298 | |
parent | Improve comments on check/lint/tidy maps (diff) | |
download | dotfiles-703c63113d6e089136259ab077422b51f636309a.tar.gz dotfiles-703c63113d6e089136259ab077422b51f636309a.zip |
Make all lint/check/tidy maps local and silent
That is, apply <buffer> and <silent> to each of them, to make them only
apply to the current buffer and to prevent them from echoing the command
they're running.
-rw-r--r-- | vim/ftplugin/html.vim | 4 | ||||
-rw-r--r-- | vim/ftplugin/perl.vim | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/vim/ftplugin/html.vim b/vim/ftplugin/html.vim index 520e4fe2..f16bc8cf 100644 --- a/vim/ftplugin/html.vim +++ b/vim/ftplugin/html.vim @@ -1,5 +1,5 @@ " Run `tidy -errors -quiet` over buffer -nnoremap <LocalLeader>c :write !tidy -errors -quiet -utf8<CR> +nnoremap <buffer> <silent> <LocalLeader>c :write !tidy -errors -quiet<CR> " Make a bare URL into a link to itself function! s:UrlLink() @@ -16,4 +16,4 @@ function! s:UrlLink() normal! a</a> endfunction -nnoremap <silent> <LocalLeader>r :<C-U>call <SID>UrlLink()<CR> +nnoremap <buffer> <silent> <LocalLeader>r :<C-U>call <SID>UrlLink()<CR> diff --git a/vim/ftplugin/perl.vim b/vim/ftplugin/perl.vim index 3355227e..38c3308b 100644 --- a/vim/ftplugin/perl.vim +++ b/vim/ftplugin/perl.vim @@ -1,6 +1,6 @@ " Run `perl -c` over buffer -nnoremap <LocalLeader>pc :write !perl -c<CR> +nnoremap <buffer> <silent> <LocalLeader>c :write !perl -c<CR> " Run `perlcritic` over buffer -nnoremap <LocalLeader>pl :write !perlcritic<CR> +nnoremap <buffer> <silent> <LocalLeader>l :write !perlcritic<CR> " Filter buffer through `perltidy` -nnoremap <LocalLeader>pt :%!perltidy<CR> +nnoremap <buffer> <silent> <LocalLeader>t :%!perltidy<CR> |