What's your favorite CLI text editor?

I’ll go first. :grin:

ne, the “Nice Editor”. BTW: The SSL on their website is very badly configured.

I like the sensible key bindings, and the menu that appears along the top when you tap Escape twice.

3 Likes

Never heard of that before. I’m a vim user myself, although I use nvim right now.

I’ll give ne a try.

3 Likes

Nano or mg. I acquired a taste for nano after using Arch a lot as it WAS the default text editor for that. I use mg sometimes because I like easy it is and I’m used to it being the a editor that comes with OpenBSD’s base, along with vi.

If it’s going to be cli most likely use-case is systems admin so vim most likely.

I’m fairly used to vim now. Know some of key bindings and options, have my own vimrc, but never really got far into it.

To be honest I just use the default of whatever is installed in the current distro I’m running. I don’t use a text editor in the CLI often enough to use more than the basics. Nano seems to be the one most commonly installed in Debian based distro’s so it is the one I have used most often.

2 Likes

At first I used vim. Then I just went with the default of nano, just like you (just deferring to the default which the OS offers).

Then one day, I asked myself, “Hey, it’s 2019, why am I not using Ctrl+X for Cut, Ctrl+C for Copy, and Ctrl+V for paste, as is the case with all the graphical editors I’m using? Surely some CLI editor provides that!” Then after some searching, I found that ne provided these sensible bindings.

Trivia: Do you know what nano’s claim to fame was (other than it’s tiny size), which made it deserve to be chosen as the default CLI text editor? Here’s why: “it emulates the Pico text editor, part of the Pine email client.”

3 Likes

VI or Vim If I’m in a pure CLI environment, because I went through a phase some years ago when I used it for everything and I still remember the basic keystrokes (search/replace, switching modes, how to quit), but on my main machine I have “EDITOR=/usr/bin/gedit” at the bottom of my .bashrc.

1 Like

Hey, you know where I first came across those key-bindings? Way back in the 1980s using Wordstar 1.4 (I think) on CP/M. Wordstar was what passed for a wordprocessor in those days.

3 Likes

There’s an open source clone of Wordstar! - pre WYSIWYG era :slight_smile: I used Wordstar very little as I was very young then and didn’t move to DOS until a good few years later and so don’t remember its shortcuts. It was Wordstar vs Wordperfect in the old days before Windows 3 and Microsoft Word gained dominance… My first use of these shortcuts would’ve been from MS Word 2. I always thought they’d been “borrowed” from Mac, but maybe they originated in Wordstar.

I don’t know if they come ORIGINALLY from Wordstar, before Wordstar it was I think WordMaster, which borrowed from NED, which was an extention of ED… blah blah blah (it’s in Wikipedia somewhere or the http://wordstart.org site A Potted History of WordStar. Somewhere in all that the key bindings originated… unless someone knows of an even older source (medieval scribes with magic quill pens?).

1 Like

Mea culpa, I am wrong, it wasn’t Wordstar, my senility is getting worse. That was different

WordStar 3 for DOS Commands Reference

Now I’m wondering where I actually did first come across those key commands…

1 Like

I like the magic quill pens theory :wink:

I forced myself to learn vim, and it was difficult, but now I want to use vim keybindings in Microsoft Word to navigate in my documents at work too :frowning:
but I installed gvim on my office pc too, for the occasional plain text editing :smiley:

1 Like

I finally started learning vim when it seemed pretty unavoidable for serious systems admin as it seems to be the only editor that’s pretty-much guaranteed to be on a system that might have gone wrong. I was very surprised at how much sense the vim system makes, actually, and also started wondering about using the keybindings in other applications!

In terms of a CLI text editor, it’s Nano for me. Easy & quick to use (unlike Vim), it does the job!

1 Like

I use vim. I am just used to it.

1 Like

In the past (8 years ago), I used vim to write everything, and since I don’t code, it was a lot of plaintext docs or markup with ASCIIDOC syntax. I remember being more efficient with vim back in the day. Although, I still often start up vim to edit something when I’m in the CLI, I liked @WalJT comment about tying $EDITOR to gedit in the .bashrc.

Recently, I started learning emacs simply because DT (Distrotube) inspired me to give it a try. I’m having fun, but it has a learning curve before I feel like I’m being productive. Little configuration issues bug me like how it doesn’t wrap the text on the word, but by the size of the window or not at all. I’m sure there is some setting (elisp code) that I can put into my .emacs file to get it to wrap the way I expect it to in plaintext documents, but I have yet to get that far. Then there is the whole “copy/paste” issue that I haven’t nailed down yet so that I can quickly copy from any app and into any app without issue when either vim or emacs is involved, this too is because I don’t have things configured just right for my workflow. All of the time I’m putting into this makes me wonder if I wouldn’t be better off just sticking to gedit and spending time learning to code in some scripting language instead.

1 Like

I’ve used vim (or vi) for over 30 years now, but for the last maybe 1-2 years I’ve switched my main editor to Emacs (with Doom Emacs configuration and evil keybindings of course). I’m really loving Emacs especially because of org-mode and magit, but I still use vi (or actually nvim now) for anything that I need to quickly edit from the terminal.

1 Like

Nano, I do not need more.

2 Likes