又重新过了一遍vimtutor
来源:互联网 发布:数控剪板机如何编程 编辑:程序博客网 时间:2024/04/29 19:03
笔记如下。挖个坑,便于以后查阅
Lesson1.1: hjkl-h(left), j(donw), k(up), l(right)
Lesson1.2: q!
Lesson1.3: x
Lesson1.4: i
Lesson1.5: a(append)
Lesson1.6: wq
Lesson2.1: dw
Lesson2.2: d$(delete to the end of the line)
Lesson2.3: motion
dw(delete until the start of the next word, EXCLUDING its first character)
de(delete to the end of the current word, INCLUDING the last character)
d$(delete to the end of the line, INCLUDING the last character)
Lesson2.4: Using a count for a motion
2w(Move the cursor two words forward)
3e(Move the cursor to the end of the third word forware)
0(Move to the start of the line)
$(Move to the end of the line)
Lesson2.5: Using a count to delete more
d2w(Delete 2 words)
Lesson2.6:
dd(delete current line)
2dd(delete 2 lines)
Lesson2.7:
u(undo previous actions)
U(undo all the change on a line)
另外:w(forward just 1 word)
Lesson3.1: p(paste/put)
Lesson3.2: r(replace one letter)
Lesson3.3: ce(To change until the end of a word)---deletes the word and places you in Insert mode.
Lesson3.4: c [number] motion more changes using c
Lesson4.1: Cursor location and file status
Ctrl + g (show filename and the position in the file)
G(Move you to the bottom of the file)
gg(Move you to the start of the file)
line + G(Go to line)
:line(Go to line)
Lesson4.2: Search command
/ (Search forward)
? (Search backward)
ctrl + o (Go back to where you are before search)
n(next occurrence)
N(previous occurrence)
Lesson4.3: % (marching ")]}" )
Lesson4.4:
:%s/old/new/g (to substitute new for old in the whole file)
:#,#s/old/new/g (from line # to #, substitute new for old)
:%s/old/new/gc (with a prompt whether to substitute or not)
:s/old/new (to substitute new for the first old in current line)
:s/old/new/g (to substitue new for old int current line)
Lesson5.1: Execute an external command
:!Command
Lesson5.2: More on writing files
:!w test.txt
Lesson5.3: Selecting text to write
v motion :w FILENAME
v motion :d(delete selected text)
Lesson5.4: Retrieving and merging files
:r filename(将filename文件中的内容插入光标处)
:r !ls(将ls命令的输出插入光标处)
Lesson6.1: The open command
o:(在下一行输入)
O:(在上一行输入)
Lesson6.2: The append command
a:(在光标处插入)
A:(在行尾插入)
e:(将光标移至词尾)
Lesson6.3: Another way to replace
R:(连续替换)
Lesson6.4: Copy and paste
y(yank/copy)
p(paste)
Lesson6.5: Set option
set nu(设置行号)
Lesson7.1: Getting help
F1
:help
Lesson7.2: Create a startup script
.vimrc
Lesson7.3: Completion
一定要多加练习,不然用不了多久就又忘了。
- 又重新过了一遍vimtutor
- 最近把TS流格式又重新理了一遍
- 过了一遍《linux程序设计》
- 赶时髦过了一遍Swift 语言....
- 赶时髦过了一遍Swift 语言....
- 第三章看了一遍,又明白了很多
- 【笔记】抽空重新查看了一遍linux c函数
- 正则表达式语法 (今天又复习了一遍)
- [C#]把文件分割又重写了一遍
- 又看了一遍《不能说的秘密》
- 又看了一遍鲁迅的《祝福》
- 输出多个菱形又写了一遍!
- 又把字符串自增写了一遍
- 今天把吃饭的家伙又清洗了一遍
- codevs2645(又写了一遍spfa,有注意事项)
- w3school上系统过了一遍Jquery的总结
- 自考又只过了一门
- Activity或者FragmenitActivity锁屏后会被销毁一遍,解锁时又重新加载onCreate的问题解决
- Monte Carlo method
- 在seam框架下jquery前端技术的使用
- 年过了,离开家离开了父母, 莫忘感恩! [22P]
- Android游戏框架Libgdx使用入门
- Python.h:No such file or directory
- 又重新过了一遍vimtutor
- Brand-new 2011 career & work
- USB驱动编写指南
- Asp.net中的web.config配置
- 实战Linux下VMware虚拟机根目录空间扩充
- [译]OOSE第6章:Architecture 体系结构 6.7 实施模型 & 6.8 测试模型 & 6.9 总结
- 7 种流行 PHP IDE 的比较
- 股票操作记录 2011.2.14
- Android 启动分析 init进程 init.rc