Update personal help file
Also added keybind (`<leader>h`) to open it automatically
This commit is contained in:
@@ -4,53 +4,61 @@ A cheat sheet for my vim customizations
|
|||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
|
## Macros
|
||||||
|
|
||||||
|
`q`<register><commands>`q` - record macro
|
||||||
|
`@`<register> - replay macro
|
||||||
|
|
||||||
## Spelling
|
## Spelling
|
||||||
|
|
||||||
* `<ctrl>-p` - auto-complete spelling suggestions
|
* `]s` - move to next misspelled word
|
||||||
* `<F10>` - toggle spellcheck
|
* `[s` - move to previous misspelled word
|
||||||
|
* `z=` - suggest correction
|
||||||
|
* `<ctrl>-p` - auto-complete spelling suggestions
|
||||||
|
* `<F10>` - toggle spellcheck
|
||||||
|
|
||||||
## Highlights
|
## Highlights
|
||||||
|
|
||||||
* `<leader><leader>` - turn off search highlight
|
* `<leader><leader>` - turn off search highlight
|
||||||
* `<Leader>C` - toggle row/column cursor
|
* `<Leader>C` - toggle row/column cursor
|
||||||
|
|
||||||
## Buffers
|
## Buffers
|
||||||
|
|
||||||
* `<ctrl>H` - to move to previous BUFFER
|
* `<ctrl>H` - to move to previous BUFFER
|
||||||
* `<ctrl>L` - to move to next BUFFER
|
* `<ctrl>L` - to move to next BUFFER
|
||||||
* `<ctrl>J` - to move to lower PANE
|
* `<ctrl>J` - to move to lower PANE
|
||||||
* `<ctrl>K` - to move to upper PANE
|
* `<ctrl>K` - to move to upper PANE
|
||||||
|
|
||||||
* `<leader>s` - to save buffer
|
* `<leader>s` - to save buffer
|
||||||
* `<leader>c` - to close buffer
|
* `<leader>c` - to close buffer
|
||||||
* `<leader>a` - to abandon unsaved buffer
|
* `<leader>a` - to abandon unsaved buffer
|
||||||
|
|
||||||
* `<leader>x` - bring up the copy buffer
|
* `<leader>x` - bring up the copy buffer
|
||||||
* `<F5>` - refresh buffer
|
* `<F5>` - refresh buffer
|
||||||
|
|
||||||
* `<leader>r` - open registers
|
* `<leader>r` - open registers
|
||||||
|
|
||||||
## FZF
|
## FZF
|
||||||
|
|
||||||
* `<leader>f` - open FZF files
|
* `<leader>f` - open FZF files
|
||||||
* `<leader>b` - open FZF buffers
|
* `<leader>b` - open FZF buffers
|
||||||
|
|
||||||
## Text bubbling (http://vimcasts.org/episodes/bubbling-text/)
|
## Text bubbling (http://vimcasts.org/episodes/bubbling-text/)
|
||||||
|
|
||||||
After text selection (`<ctrl-v>`)
|
After text selection (`<ctrl-v>`)
|
||||||
|
|
||||||
* `<ctrl>k` - bubble up
|
* `<ctrl>k` - bubble up
|
||||||
* `<ctrl>j` - bubble down
|
* `<ctrl>j` - bubble down
|
||||||
|
|
||||||
## Date and Time stamps
|
## Date and Time stamps
|
||||||
|
|
||||||
* `<F2>` - insert %Y-%m-%d %H:%M:%S
|
* `<F2>` - insert %Y-%m-%d %H:%M:%S
|
||||||
* `<F3>` - insert %Y-%m-%d %a
|
* `<F3>` - insert %Y-%m-%d %a
|
||||||
* `<F4>` - insert %H:%M
|
* `<F4>` - insert %H:%M
|
||||||
|
|
||||||
## Snippets
|
## Snippets
|
||||||
pre-made files inserted from `.vim/templates`
|
pre-made files inserted from `.vim/templates`
|
||||||
|
|
||||||
* `,sh` - insert shell header
|
* `,sh` - insert shell header
|
||||||
* `,md` - insert markdown header
|
* `,md` - insert markdown header
|
||||||
* `,ban` - insert ASCII banner
|
* `,ban` - insert ASCII banner
|
||||||
|
|||||||
4
.vimrc
4
.vimrc
@@ -34,6 +34,10 @@ filetype plugin on
|
|||||||
" Native Markdown syntax highlighting for specified languages
|
" Native Markdown syntax highlighting for specified languages
|
||||||
let g:markdown_fenced_languages = ['html', 'python', 'sh', 'vim']
|
let g:markdown_fenced_languages = ['html', 'python', 'sh', 'vim']
|
||||||
|
|
||||||
|
|
||||||
|
" Open my personal helpfile
|
||||||
|
nmap <leader>h :e $HOME/.vim/vim-keys-help.md<CR>
|
||||||
|
|
||||||
" ---------------------------------------------------------------------------------------------------------------------
|
" ---------------------------------------------------------------------------------------------------------------------
|
||||||
" ==> From Vim Zero: https://www.oliversherouse.com/2017/08/21/vim_zero.html
|
" ==> From Vim Zero: https://www.oliversherouse.com/2017/08/21/vim_zero.html
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user