mirror of
https://github.com/adambard/learnxinyminutes-docs.git
synced 2024-12-23 17:41:41 +00:00
[vim/en] add additional fold commands and visual regex; reformat
accordingly
This commit is contained in:
parent
a52f5d2c26
commit
d259c3bc42
@ -59,6 +59,7 @@ specific points in the file, and for fast editing.
|
||||
:%s/foo/bar/g # Change 'foo' to 'bar' on every line in the file
|
||||
:s/foo/bar/g # Change 'foo' to 'bar' on the current line
|
||||
:%s/\n/\r/g # Replace new line characters with new line characters
|
||||
:'<,'>s/foo/bar/g # Change 'foo' to 'bar on every line in the current visual selection
|
||||
|
||||
# Jumping to characters
|
||||
|
||||
@ -196,10 +197,21 @@ A few important examples of 'Verbs', 'Modifiers', and 'Nouns':
|
||||
|
||||
# Fold text
|
||||
zf # Create fold from selected text
|
||||
zd # Delete fold on the current line
|
||||
zD # Recursively delete nested or visually selected folds
|
||||
zE # Eliminate all folds in the window
|
||||
zo # Open current fold
|
||||
zO # Recursively open nested or visually selected folds
|
||||
zc # Close current fold
|
||||
zC # Recursively close nested or visually selected folds
|
||||
zR # Open all folds
|
||||
zM # Close all folds
|
||||
za # Toggle open/close current fold
|
||||
zA # Recursively toggle open/close nested fold
|
||||
[z # Move to the start of the current fold
|
||||
]z # Move to the end of the current fold
|
||||
zj # Move to the start of the next fold
|
||||
zk # Move to the end of the previous fold
|
||||
```
|
||||
|
||||
## Macros
|
||||
|
Loading…
Reference in New Issue
Block a user