当前位置:网站首页>VIM usage
VIM usage
2022-06-24 21:06:00 【AcTarjan】
3 Patterns
- Command line mode (command mode)
- Insertion mode (insert mode)
- last line node (last line mode)
Mode switch
- start-up vim Enter command line mode
- Press down i Key into insert mode
- Input “:” Enter the baseline command mode
- Press... In insert mode Esc Key to enter command line mode
- Press... In the baseline command mode Esc Key or delete “:” Enter command line mode
Command line mode
# Find and replace
/< What to look for >
The result of the search is next 、 the previous :n N
# edit
Undo last operation :u
Delete the cursor position character :x
Delete a line :dd
Duplicate a row :yy
Paste one line below the cursor 、 Last line :p P
Insert an empty line next to the cursor 、 Last line :o O( Will enter edit mode )
Insert at end of current line :A( Will enter edit mode )
Move the cursor to the beginning and end of the line :HOME key END key
Move the cursor to the first non empty character of the line , The last non empty character :^ $
Move the cursor to x That's ok 、 first line 、 The last line :xG gg GG
last line node
# Replace
Replace the first... In the current line 、 all :s/< Original value >/< Replacement value > s/< Original value >/< Replacement value >/g
Replace the first of all lines 、 all :%s/< Original value >/< Replacement value > %s/< Original value >/< Replacement value >/g
# Exit and save
Exit without saving :q!
preservation :w
Save and exit :wq
边栏推荐
- The Google File System (GFS) learning notes
- 使用gorm查询数据库时reflect: reflect.flag.mustBeAssignable using unaddressable value
- The latest simulated question bank and answers of the eight members (Electrical constructors) of Sichuan architecture in 2022
- C langage pour le déminage (version simplifiée)
- How to apply agile development ideas to other work
- Stackoverflow annual report 2022: what are developers' favorite databases?
- 在Dialog中使用透明的【X】叉叉按钮图片
- 顺序表的基本操作
- I feel that I am bald again when I help my children with their homework. I feel pity for my parents all over the world
- It was Tencent who jumped out of the job with 26k. It really wiped my ass with sandpaper. It gave me a hand
猜你喜欢

Camera rental management system based on qt+mysql

Grating diffraction

Bridging mode -- law firm

Adding subscribers to a list using mailchimp's API V3

What does virtualization mean? What technologies are included? What is the difference with private cloud?

Handling of garbled JMeter response data - three solutions

伯克利、MIT、劍橋、DeepMind等業內大佬線上講座:邁向安全可靠可控的AI

JMeter parameterization

基于QT+MySQL的相机租赁管理系统

JMeter response assertion
随机推荐
Set up your own website (14)
Reflection - class object function - get method (case)
Nifi fast authentication configuration
Handling of garbled JMeter response data - three solutions
After idea installs these plug-ins, the code can be written to heaven. My little sister also has to arrange it
The Google File System (GFS) learning notes
Background operation retry gave up; KeeperErrorCode = ConnectionLoss
科创人·味多美CIO胡博:数字化是不流血的革命,正确答案藏在业务的田间地头
基于QT+MySQL的相机租赁管理系统
Is the waiting insurance record a waiting insurance evaluation? What is the relationship between the two?
Byte and Tencent have also come to an end. How fragrant is this business of "making 30million yuan a month"?
Summary of idea practical skills: how to rename a project or module to completely solve all the problems you encounter that do not work. It is suggested that the five-star collection be your daughter
Open programmable infrastructure (OPI) project, redefining dpu/ipu
Sequential stack traversal binary tree
虚拟化是什么意思?包含哪些技术?与私有云有什么区别?
Mapstacks: data normalization and layered color layer loading
The AI for emotion recognition was "harbouring evil intentions", and Microsoft decided to block it!
Internet of things? Come and see Arduino on the cloud
DHCP operation
The difference between RPC and restful