From 562b5ddc1e719a36498d2ccef3a6f63a7480913b Mon Sep 17 00:00:00 2001 From: quilime Date: Sat, 2 Jan 2021 12:50:22 -0800 Subject: [PATCH] Update Vim-Cheatsheet.md --- Vim-Cheatsheet.md | 58 +++++++++++++++++++++++------------------------ 1 file changed, 29 insertions(+), 29 deletions(-) diff --git a/Vim-Cheatsheet.md b/Vim-Cheatsheet.md index 1a4e447..8160870 100644 --- a/Vim-Cheatsheet.md +++ b/Vim-Cheatsheet.md @@ -11,64 +11,64 @@ own. If you create your own cheatsheat, use Vim to create it. ## Config - - For Vim: `~/.vimrc.` + - For Vim: `~/.vimrc.` Disable cursor keys. (They will still work in Insert mode) ``` - " remove cursor keys - noremap - noremap - noremap - noremap +" remove cursor keys +noremap +noremap +noremap +noremap ``` ## Insert Mode - - `i` - `i`nsert content before selected char - - `a` - Insert content `a`fter select char - - `A` - Insert content `A`fter last char on line - - `o` - `o`pen new line below current - - `O` - `O`pen new line above current - - `esc`, `ctrl-c` - Exit Insert mode + - `i` - `i`nsert content before selected char + - `a` - Insert content `a`fter select char + - `A` - Insert content `A`fter last char on line + - `o` - `o`pen new line below current + - `O` - `O`pen new line above current + - `esc`, `ctrl-c` - Exit Insert mode ## Visual Mode - - `v` - Enter `v`isual mode - - `d` - `d`elete. Like "ctrl-x - cut", puts text in clipboard - - `y` - `y`ank. Like "ctrl-c - copy", puts text in clipbaord - - `c` - `c`hange. Deletes (cuts) and enter Insert mode immediately + - `v` - Enter `v`isual mode + - `d` - `d`elete. Like "ctrl-x - cut", puts text in clipboard + - `y` - `y`ank. Like "ctrl-c - copy", puts text in clipbaord + - `c` - `c`hange. Deletes (cuts) and enter Insert mode immediately ## Normal Mode Commands - - `dd` - `dd`elete line (places line in clipboard) + - `dd` - `dd`elete line (places line in clipboard) ### Files - - `:e` or `:edit` - Edit (open) new file in current buffer - - `:Vex` - Open `V`ertical file `ex`plorer - - `:Hex` - Open `H`orizontal file `ex`plorer + - `:e` or `:edit` - Edit (open) new file in current buffer + - `:Vex` - Open `V`ertical file `ex`plorer + - `:Hex` - Open `H`orizontal file `ex`plorer ### Tabs - - `:tabnew` or `:tabe` - Open a new tab. - - `:tabclose` or `:tabc` - Close the current tab. - - `:tabonly` or `:tabo` - Close every other tab except the current one. - - `gt` - `g`o `t`o next tab - - `gT` - `g`o `T`o previous tab + - `:tabnew` or `:tabe` - Open a new tab. + - `:tabclose` or `:tabc` - Close the current tab. + - `:tabonly` or `:tabo` - Close every other tab except the current one. + - `gt` - `g`o `t`o next tab + - `gT` - `g`o `T`o previous tab ## References Vim cheatsheet references - - [Vim for Beginners](https://thevaluable.dev/vim-for-beginners/) - - [Vim for Intermediate Users](https://thevaluable.dev/vim-intermediate/) + - [Vim for Beginners](https://thevaluable.dev/vim-for-beginners/) + - [Vim for Intermediate Users](https://thevaluable.dev/vim-intermediate/) ## Vim & Neovim - - [Neovim](https://neovim.io/) - - For Neovim: ~/.config/nvim/init.vim or ~/nvim/init.vim (depending on + - [Neovim](https://neovim.io/) + - Neovim Config: ~/.config/nvim/init.vim or ~/nvim/init.vim (depending on the value of the environment variable $XDG_CONFIG_HOME). -- 2.34.1