Professional Documents
Culture Documents
Basic Vim Commands - For Getting Started (Example)
Basic Vim Commands - For Getting Started (Example)
1. Insert mode (Where you can just type like normal text editor. Press i for insert
mode)
2. Command mode (Where you give commands to the editor to get things done .
Press ESC for command mode)
p - puts the previously deleted text after the cursor(Type dd to delete the line
and store it in a Vim register. and p to put the line)
r - to replace the letter e.g press re to replace the letter with e
ce - to change until the end of a word (place the cursor on the u in lubw it will
delete ubw )
ce - deletes the word and places you in Insert mode
G - to move you to the bottom of the file.
gg - to move you to the start of the file.
Related protips:
Written by
shiva kumar
Recommend
Say Thanks
Respond
Related protips
11 Responses
hauleth
Also nice is :xa which save and quit all files. In case to use it as ZZ (save and quit) I have
mapped some more:
map ZX :cq " quit and return error (helpful when using Vim with Git)
map ZA :qa " quit all buffers
shiva
Nice .. Thanks @hauleth :)
mislav
For beginners/intermediate: Vim Revisited is my article where I present similar information but
in a more structured format.
shiva
@mislav i think the links is broken
mislav
Thanks, bad paste. Now fixed
cannon10100
There's also :x, which contextually saves the current document if changes have been made
and exits, or simply exits if no changes have been made. Equivalent to :wq
I recommend new users go pimp out there vim with the plugins ASAP to get a better
impression of its coolness.
Me, I hooked up to this fellas github & followed his README to get a great series of bundles
that all auto-install & bring colour & interest.
https://github.com/gezpage/dotfiles
PyDevTeam
Thank you for the great article!
HuyenPham
The best movie program today is updated on the showbox application. showboxvpn provider
brings the best movie showbox app available today!
RyanHillier
Thank you very much for sharing this information. This is very valuable information for me
because I'm just learning.
2 months ago
·
Post
Best
#Vim Authors
shiva
880K
#vim
#ruby
#javascript
kennu
171.1K
#vim
#Python
#C++
christianrojas
118.9K
#vim
#Ruby
#JavaScript
sickill
73.6K
#vim
#Clojure
#ClojureScript
croaky
56.33K
#vim
#Ruby
#Shell
Related Tags
Filed Under
Tools
@coderwall
APM product comparisons Contact
Privacy
Terms
Copyright 2021