Wiki

by yszheda

View project onGitHub

Tip 53: Mark Your Place and Snap Back to It

Return to the top: <<Practical Vim>>

  • m{a-zA-Z}: marks the current cursor location with designated letter

References

# If you open the file in vim,
# then you can \"ayy@a the next line to execute the vim command: 
:h m
  • `{mark}: moves the cursor on the first non-whitespace character

References

# If you open the file in vim,
# then you can \"ayy@a the next line to execute the vim command: 
:h mark-motions

Automatic Marks

Keystrokes Buffer Contents
`` Position before the last jump within current line
`. Location of last change
`^ Location of last insertion
`[ Start of last change or yank
`] End of last change or yank
`< Start of last visual selection
`> End of last visual selection