nano常用指令
搜索
按Ctrl+W,然后输入你要搜索的关键字,回车确定。这将会定位到第一个匹配的文本,接着可以用Alt+W来定位到下一个匹配的文本。
指定行
ctrl + shift + -
全选
Cursor at the beginning of a file
Ctrl6 to set a mark
AltShiftT (or try AltT) to cut to the end of the file
If AltT doesn’t work, try CtrlK
to just copy the file content do CtrlU to uncut the text again
删除行
ctrl + k
粘贴
ctrl + u
查看当前行号
ctrl + c
copy
on mac M stand for esc
^^ (M-A) Mark text starting from the cursor position
M-^ (M-6) Copy the current line and store it in the cutbuffer
翻页
用Ctrl+Y到上一页,Ctrl+V到下一页
移动到文件尾
Esc 按一下就可以,不需要一直按着
Esc then /
跳转到文件第一行
Esc + \
保存
使用Ctrl+O来保存所做的修改
退出
按Ctrl+X