11 Nano shortcuts that you should know

Created January 12, 2021

Introduction

Probably everyone that uses a Linux OS is familiar with what nano is. But if you aren't aware, don't worry. Nano is a Unix and Linux operating system command line text editor. What this means is that this is essentially a text editor built into your terminal. How awesome is that!

Of course, it can not be compared to other text editors like VSCode or Sublime Text or vim. Nonetheless, it's still handy and efficient. But unfortunately, most people don't use nano to it's fullest potential. And the reason is being that nano keyboard shortcuts are different than what we are used to.

In this post, we are going to explore the 11 nano shortcuts that you must know. We are going to group the shortcuts in different groups. Let's start with:

Moving around

One of the most challenging thing in nano is moving around. One of the most painful things is when you have to go to the end of a line, and you have to press the right arrow key a million times. Now I know that this sounds super lazy, but imagine when you have to do this to 20 different lines. It's gonna take an annoying amount of time. That's why the movement shortcuts are one of the most important to use in nano. Here are the top ones that you should definitely remember.

Ctrl+A
Ctrl+E
Ctrl+Y
Ctrl+V

Editing

Another painful thing is when you make an error and have no idea how to undo it. Well in most cases you close the file without saving the changes and start all over. That's why learning the main editing shortcuts is gonna save you quite a lot of time.

Ctrl+K 
Ctrl+U  
Alt+U 
Alt+E   

Deleting

And the final group is deleting. Imagine you add a ton of text that you want to be removed immediately. Well, it sure is going to take you a long time to remove if you don't know these shortcuts.

Alt+Bsp 
Ctrl+Del    
Alt+Del 

Conclusion

Not everybody uses Nano, and some prefer vim or emacs. But it is good to know some handy shortcuts which could help you if you ever need to use Nano.

Speaking of text editors, be sure to check out this post on VScode shortcuts for Mac and Windows:

https://devdojo.com/bobbyiliev/top-10-vscode-shortcuts-for-mac-and-windows-to-help-you-be-more-productive

I hope that this helps!