Linux Format

GNU Nano

Version: 2.8 Web: https://nano-editor.org

-

We believe that regular Linux users should be well-versed in using a command line editor, regardless of what that editor is. Historical­ly the main console editors for UNIX-based systems were Vi and Emacs, both are still widely used by experience­d Linux geeks, but in modern times these two are often hated for Vi’s terseness and the need to learn Emacs key combinatio­ns, and that’s why many people are happy with just using Nano. This is a much simpler text editor with a user-friendly interface and only the essential features (eg. when compared to Vi or using Emacs as an entire init system!), which is fine if you only use command line editors occasional­ly in some specific cases, like editing the / etc/sudoers file or fixing some configurat­ion file, if your system doesn’t boot into graphical mode. Nano doesn’t have a ‘command mode’ and thus it is similar to classic text editors from DOS or apps like mcedit. The lower part of the screen shows references to popular actions that always stay in your sight. The minimal knowledge required to use it is Ctrl+O for saving your changes and Ctrl+X for escaping back to the console.

There are many shortcuts for navigating between lines, symbols and words in the text, mostly bound to Alt or Ctrl plus <something>, but it’s good to know that Nano can emulate Alt and Ctrl themselves. Alt is Esc and Ctrl is double Esc (Esc Esc), which gives greater flexibilit­y in certain cases.

The new Nano2.8 release marks the transition to the Gnulib library, which means a lot of changes under the hood. Users should notice better navigation across very long lines that don’t fit on screen. The Up and Down arrows together with Pg Up and Pg Dn keys now move you between visual lines instead of logical lines. Home and End keys also respect visual lines first. When working with very long lines, the first time you press Home or End, you get to the start or the end of the visual line, whereas the second press brings you to the start/ end of the logical line. To test this feature you may need to write a long command or use a smaller screen. In the latter case, Cool RetroTerm (see LXF192) would be a perfect playground!

“There are many shortcuts for navigating between lines, symbols and words.”

 ??  ?? Primitive in the eyes of greybeards, very nice for the rest!
Primitive in the eyes of greybeards, very nice for the rest!

Newspapers in English

Newspapers from Australia