Skip to content

Commit

Permalink
[vim/en] explain yank and delete at first occurrence (adambard#4050)
Browse files Browse the repository at this point in the history
yank and delete unexplained at first occurrence
not even basic requirement i.e. yank = copy

  - added draft explanations
  • Loading branch information
kevinnls authored Jan 3, 2022
1 parent 831b708 commit f6d6a9c
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions vim.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -111,14 +111,21 @@ Vim is based on the concept on **modes**.
<esc> # 'Escapes' from whichever mode you're in, into Command mode
# Copying and pasting text
# Operations use the vim register by default
# Think of it as vim's private clipboard
# Yank ~ copy text into vim register
y # Yank whatever is selected
yy # Yank the current line
# Delete ~ yank text and delete from file
d # Delete whatever is selected
dd # Delete the current line
p # Paste the copied text after the current cursor position
P # Paste the copied text before the current cursor position
x # Deleting character under current cursor position
p # Paste text in vim register after the current cursor position
P # Paste text in vim register before the current cursor position
x # Delete character under current cursor position
```

## The 'Grammar' of vim
Expand Down

0 comments on commit f6d6a9c

Please sign in to comment.