无编辑摘要
无编辑摘要
第2行: 第2行:


https://nano-editor.org
https://nano-editor.org
== 安装 ==
在Windows系统安装:<syntaxhighlight lang="powershell">
choco install nano
</syntaxhighlight>
== 使用 ==
<syntaxhighlight lang="powershell">
# 打开并编辑当前目录下的 filename.txt ,如果不存在就新建
nano filename.txt
</syntaxhighlight>
== 快捷键 ==
[https://nano-editor.org/dist/latest/cheatsheet.html Cheatsheet for GNU nano]
{| class="wikitable"
|+文件类操作
|Ctrl+S  
|保存当前文件
|-
|Ctrl+O
|“另存为”
|-
|Ctrl+X
|退出编辑器
|}
{| class="wikitable"
|+编辑类操作
|Ctrl+K  
|将当前行剪切到剪切板
|-
|Alt+6
|Copy current line into cutbuffer
|-
|Ctrl+U
|粘贴剪切板里的内容
|-
|Ctrl+]
|Complete current word
|-
|Alt+3
|Comment/uncomment line/region
|-
|Alt+U
|Undo last action
|-
|Alt+E
|Redo last undone action
|}
[[分类:代码编辑器]]
[[分类:代码编辑器]]

2025年1月5日 (日) 11:19的版本

Nano is a small and simple text editor for use on the terminal. It copied the interface and key bindings of the Pico editor but added several missing features: undo/redo, syntax highlighting, line numbers, softwrapping, multiple buffers, selecting text by holding Shift, search-and-replace with regular expressions, and several other conveniences.

https://nano-editor.org

安装

在Windows系统安装:

choco install nano

使用

# 打开并编辑当前目录下的 filename.txt ,如果不存在就新建
nano filename.txt

快捷键

Cheatsheet for GNU nano

文件类操作
Ctrl+S   保存当前文件
Ctrl+O “另存为”
Ctrl+X 退出编辑器
编辑类操作
Ctrl+K   将当前行剪切到剪切板
Alt+6 Copy current line into cutbuffer
Ctrl+U 粘贴剪切板里的内容
Ctrl+] Complete current word
Alt+3 Comment/uncomment line/region
Alt+U Undo last action
Alt+E Redo last undone action