diff options
author | Tom Ryder <tom@sanctum.geek.nz> | 2018-07-08 21:22:51 +1200 |
---|---|---|
committer | Tom Ryder <tom@sanctum.geek.nz> | 2018-07-08 21:22:51 +1200 |
commit | 8e9ccd90155a77deb96e5ff308eae88415bfa56b (patch) | |
tree | e539486b81daf22f039e34efe42d471ed76e20be | |
parent | Rename plugin maps with <Plug>(parens) (diff) | |
download | vim-diff-prune-8e9ccd90155a77deb96e5ff308eae88415bfa56b.tar.gz vim-diff-prune-8e9ccd90155a77deb96e5ff308eae88415bfa56b.zip |
Fix and extend the configuration example
-rw-r--r-- | doc/diff_prune.txt | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/doc/diff_prune.txt b/doc/diff_prune.txt index ea7fabb..f708d73 100644 --- a/doc/diff_prune.txt +++ b/doc/diff_prune.txt @@ -22,15 +22,17 @@ MAPPINGS *diff_prune-mappings* *<Plug>(DiffPrune)* A single mapping target name `<Plug>(DiffPrune)` for normal and visual modes -provided. You could put this in your `~/.vimrc` to use `<LocalLeader>p`: +provided. There is no default key mapping. You could put this in +`after/ftplugin/diff.vim` to use `<LocalLeader>p`, with `<LocalLeader>pp` to +prune the current line: > - augroup vimrc - autocmd! - autocmd FileType diff - \ nmap <buffer> <LocalLeader>p <Plug>(DiffPrune) - autocmd FileType diff - \ xmap <buffer> <LocalLeader>p <Plug>(DiffPrune) - augroup END + nmap <buffer> <LocalLeader>p <Plug>(DiffPrune) + xmap <buffer> <LocalLeader>p <Plug>(DiffPrune) + nmap <buffer> <LocalLeader>pp <Plug>(DiffPrune)_ + let b:undo_ftplugin = b:undo_ftplugin + \ . '|nunmap <buffer> <LocalLeader>p' + \ . '|xunmap <buffer> <LocalLeader>p' + \ . '|nunmap <buffer> <LocalLeader>pp' < AUTHOR *diff_prune-author* |