Nano Editor Cheatsheet

Nano File Editor Overview of nano’s shortcuts The editor’s keystrokes and their functions. File handling Keystroke Function Ctrl+S Save current file Ctrl+O Offer to write file (“Save as”) Ctrl+R Insert a file into current one Ctrl+X Close buffer, exit from nano Editing Keystroke Function Ctrl+K Cut current line into cutbuffer Alt+6 Copy current line into cutbuffer Ctrl+U Paste contents of cutbuffer Alt+T Cut until end of buffer Ctrl+] Complete current word Alt+3 Comment/uncomment line/region Alt+U Undo last action Alt+E Redo last undone action Search and replace Keystroke Function Ctrl+Q Start backward search Ctrl+W Start forward search Alt+Q Find next occurrence backward Alt+W Find next occurrence forward Alt+R Start a replacing session Deletion Keystroke Function Ctrl+H Delete character before cursor Ctrl+D Delete character under cursor Alt+Bsp Delete word to the left Ctrl+Del Delete word to the right Alt+Del Delete current line Operations Keystroke Function Ctrl+T Execute some command Ctrl+J Justify paragraph or region Alt+J Justify entire buffer Alt+B Run a syntax check Alt+F Run a formatter/fixer/arranger Alt+: Start/stop recording of macro Alt+; Replay macro Moving around...

March 23, 2023 · 2 min · by Chisqi