Live data from Hacker News

Helping a Million Developers Exit Vim

stackoverflow.blog

221–230 of 489 posts

Re: Helping a Million Developers Exit Vim

#221

Earlier quoted context omitted.

Hitting Ctrl+C still works, it tells you to type ":quit ".

If I expect Ctrl+C to quit immediately, and it doesn't quit immediately, that is not functionality that works.

You might expect it to quit immediately, but most Vim users don't (for example I have a habit of using Ctrl-C to exit insert mode). When you travel to a foreign country you shouldn't expect everybody to speak your language.

Re: Helping a Million Developers Exit Vim

#222

(Attribution is questionable, but as a geezer I feel the need to make sure the younger generations at least are familiar with this:) ed is the standard text editor Let's look at a typical novice's session with the mighty ed: golem> ed ? help ? ? ? quit ? exit ? bye ? hello? ? eat flaming death ? ^C ? ^C ? ^D ? --- Note the consistent user interface and error reportage. Ed is generous enough to flag errors, yet pruden…

I recently had to use ed. I wanted to write a handful lines of code, but for that I needed the context that was in the terminal history. I didn't want to keep switching back and for with vi. So I decided this was the time I should learn ed. It did the job it was expected to do, I was not disappointed.

Same way I came to it. It's exactly what it claims to be, nothing more or less, and it does what it does very well.

Re: Helping a Million Developers Exit Vim

#223
post #29

Earlier quoted context omitted.

dev: That just typed ':q' into the text area me: Hit escape first, then :q dev: Oh, then why doesn't say escape then :q me: welp

Except, if you hit Ctrl+C, you don't have to hit ESC. You literally type what it tells you and it works. The only way the above would work as suggested is if the person hit an insert mode key first after having typed Ctrl+C.

Weelll. The problem is that the "quit" command has an insert mode key in it. So it's quite possible to get stuck like a poster above says- enter macro recording, then insert mode, then write the letter "t".

On the other hand that only happens if you type "quit" without the colon and the message makes it very clear that the colon is part of the text you must enter:

  Type  :quit  to exit Vim
See all that whitespace? It's very hard to think the colon goes to the "Type" bit.

So you can get stuck in a dubm situation but it's not terribly easy.

Re: Helping a Million Developers Exit Vim

#224
post #171

I spent almost 10 years doing IT for a company whose backend was based entirely on as/400. If you've ever used a system like that, I'm sure you know where this is going... The console's that the front-desk or clerical users used every day had a steep learning curve. It was something that you would definitely not be able to walk up to and just intuit. However , once you figured it out, there is never going to be a fas…

There's certainly a trade-off between learning curve and long-term productivity. But the problem here is that vi/m gives shitty feedback, that's all. It should say "Press and type :quit to quit VIM" but it doesn't. Most first-time users lack a mental model of input modes, so they get stuck.

Re: Helping a Million Developers Exit Vim

#226
post #171

I spent almost 10 years doing IT for a company whose backend was based entirely on as/400. If you've ever used a system like that, I'm sure you know where this is going... The console's that the front-desk or clerical users used every day had a steep learning curve. It was something that you would definitely not be able to walk up to and just intuit. However , once you figured it out, there is never going to be a fas…

I work for a reservation systems company (a GDS) that is used by thousands of travel agencies. Of course, since the system was created 30 years ago, you were only able to create reservation with a text-based interface at the time, with short commands, inconsistent and complex flows to do some non-trivial things etc. So it's despised by newcomers because learning curve is steep. However, the company has been building…

Altea Amadeus.

And all the three big GDS need to be thrown into a fire. "Oh you want to add a person to the PNR? Well tough luck! Not a use case we handle!"

Re: Helping a Million Developers Exit Vim

#227

Earlier quoted context omitted.

And worse vim is often the default EDITOR or software's fallback in case no EDITOR is set, so you get dropped into a vim edition buffer seemingly randomly.

I'm pretty sure that I've never seen any OS/Linux distribution set default EDITOR to vim. If EDITOR is set to vim, then someone must intentionally did that.

[deleted]

Re: Helping a Million Developers Exit Vim

#228
post #90

(Attribution is questionable, but as a geezer I feel the need to make sure the younger generations at least are familiar with this:) ed is the standard text editor Let's look at a typical novice's session with the mighty ed: golem> ed ? help ? ? ? quit ? exit ? bye ? hello? ? eat flaming death ? ^C ? ^C ? ^D ? --- Note the consistent user interface and error reportage. Ed is generous enough to flag errors, yet pruden…

I find that with a specific and known edit, it's far easier to do using sed and awk. In particular awk Has better power-to-weight ratio at traditional text processing. I think typical awk scripts could very well be shorter than the equivalent python scripts that do the same thing.

I have written hundred+ line awk programs. For stream text editing it is excellent at what it does and it's install base is huge. Rarely do I encounter a *nix machine without it on there.

Re: Helping a Million Developers Exit Vim

#229
post #171

I spent almost 10 years doing IT for a company whose backend was based entirely on as/400. If you've ever used a system like that, I'm sure you know where this is going... The console's that the front-desk or clerical users used every day had a steep learning curve. It was something that you would definitely not be able to walk up to and just intuit. However , once you figured it out, there is never going to be a fas…

> My point is that just because something has a steep learning curve, that doesn't necessarily mean that it's a bad design.

It does if the app is aimed at companies with high turnover where said learning curve poses a continual problem for users.

Re: Helping a Million Developers Exit Vim

#230
post #197

Earlier quoted context omitted.

I'm pretty sure that I've never seen any OS/Linux distribution set default EDITOR to vim. If EDITOR is set to vim, then someone must intentionally did that.

Right. Many programs react to an unset EDITOR variable by assuming vi though. This makes sense, of course, as virtually all systems are going to have some implementation of vi installed. Even the almighty ed tends to be missing from the default install of some recent Linux distributions.

That's probably out of mercy- saves people from getting stuck in ed.
Post reply on HN