Text editor recs?
Nov. 29th, 2010 12:50 pm![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
![[community profile]](https://www.dreamwidth.org/img/silk/identity/community.png)
I want a command line text editor that can do a soft-word wrap. By "soft," I mean that long lines won't scroll past the right edge of my screen, but when I save my file, I won't discover it's had a mess of line breaks inserted into my text every seventy-odd chars.
I'd be mostly writing in natural English, so emacs or vi are rather more complicated than I'm looking for, but if you tell me one of them is my only solution, I will cry and then suck it up and learn to use whichever.
I'd be mostly writing in natural English, so emacs or vi are rather more complicated than I'm looking for, but if you tell me one of them is my only solution, I will cry and then suck it up and learn to use whichever.
no subject
Date: 2010-11-29 07:00 pm (UTC)nano
does what you need it to. It's pretty much the most basic of the command line editors.You can get it to soft wrap by pressing the "esc" button and then a $ sign.
no subject
Date: 2010-11-29 07:56 pm (UTC)But thank you very much, I didn't know nano could do that!
no subject
Date: 2010-11-29 08:20 pm (UTC)For me, it's because it is so incredibly fast to be a vim power-user. The learning curve is steep, but once you've gone through that process, you have immense power in a multitude of single-keystroke commands. You basically have an embedded sed processor; there are very few times I will do a one-shot regular expression with sed, awk, or command-line perl instead of just doing it natively in vim. One keystroke to search forward, one keystroke to search backward, macros I can define in my vimrc, All kinds of nice goodies. Soft-wrap, BTW, is ":set wrap linebreak textwidth=0".
That being said, that's why vim is a power tool for me. There's no reason to think it necessarily would be for you, any more than Emacs is the right one for me, or Microsoft Word is the right one for me.
(Although one advantage of vi is that it is almost but not quite the lowest common denominator installed on a bare-bones system -- with the lowest common denominator being ed, on older systems -- and if you find yourself in a situation where you can't boot up the machine into a more friendly state into you can get into a text editor, being able to do basic editing in vi is essential.)
no subject
Date: 2010-11-29 10:14 pm (UTC)I'm a vim power user, and while I like to tease emacs power users, it's stupid to get into a flamewar about it. It's best that people use the editor they're comfortable with using, and I reckon that the only difference between emacs and vim in the "comfort" level is whichever editor one was exposed to first is the one that one is going to be more comfortable with.
no subject
Date: 2010-11-30 09:12 pm (UTC)That's pretty much my opinion, too - I'm also a vim user, but I attribute this not to any advantage of vim's but merely to the fact that I was exposed to vi fairly early on in my use of computers. Had I been taught emacs instead, I'm sure I would be an avid emacs user these days.
no subject
Date: 2010-12-01 12:04 pm (UTC)Still kind of sucks when your first exposure is "neither" though. I doubt the major Unix editors will ever feel right. :-/