“That answer is what in fact made me properly consider Vim ten years ago,” remembered one commenter. Yet mixed in with the comments were some genuine appreciation for Stack Overflow’s answer. After the URL to the original question was posted on Reddit’s programming forum, it drew over 5,000 upvotes - and another 660 comments. Last week Reddit users couldn’t resist celebrating the 10th anniversary of the question. And while it took almost five years to reach 1 million views, in the five years since it’s received another 1.7 million views - for a total of 2.7 million. Answers to the question have been lovingly maintained and curated over the last 10 years. Ten years ago someone asked “How do I exit Vim?” on Stack Overflow - and in the decade since the question has been upvoted 4,786 times (and bookmarked by Stack Overflow users over a thousand times). There’s also a joyful thrill of recognition when geeks stumble across reminders of just how common the problem may be. Ps ax | grep vim | grep -v grep | awk '' | xargs -n1 kill -9Commenters on the video responded with exaggerated gratitude, with one claiming they’d been trapped in Vim for an entire week, and another adding “Until now I used to press the power button to exit vim” It involves suspending the foreground Vim process (using Ctrl-Z), and then pulling up a list of all active processes (using ps ax), grepping for all the processes containing the string vim - while filtering out that grep process (which also contains the string vim) - and then using Awk to format the results so an xargs comand can kill the Vim-running process. (“Make sure to save regularly.”)Ī 2019 YouTube video shows an even more convoluted solution. Currently, GitHub even shows 77 contributors to a repository titled “ How to Exit Vim.” For example, one suggests the best way is to edit your shell’s alias file so that “vim” gets mapped to a command launching vim processes that time out and end after exactly 600 seconds. Yet, so many novice users have gotten tripped on exiting Vim, that the instructions are now displayed prominently on its welcome screen when the software is launched - even before the Help command.Īnd typing Ctrl-C twice in Vim now pulls up a hint at the bottom of your screen.īut over the years, the difficulty became the affectionate target of some gentle geek satire. ![]() The trick is to learn how to effortlessly toggle between the two. And there is the edit mode, where you write your code, book proposals, etc. One is a command mode to save files, add formatting, quit the program itself, and such. When you’re typing away in Vim, it won’t accept commands like “q” for quit until you first hit the escape key - and even then, commands like “quit” are preceded by a colon.Ī wise Linux greybeard once pointed out to us that Vim is no different than Microsoft Word in that both have two modes. Tomasz Łakomy □ v □□ August 27, 2018īasically, it’s an essential function that can’t always be executed in an intuitive way. I’ve spent the next 15 minutes exiting vim on 7 different machines. I wanted to open a file in the terminal to show them what’s inside and I did my usual: So here’s a quick story: Last weekend I had a class of 7 students learning JavaScript. ![]() Getting trapped in Vim in a decades-old text editor remains a common if not universal experience for struggling first-time users. Maybe there’s some secret pride in the fact that as powerful as Vim may be - there is still a learning curve. It was included in the initial Berkeley Software Distribution Unix, released in 1978 and has been in the Unix/Linux developer’s toolbox ever since.)īut it also speaks to a larger truth, a fond and knowing acknowledgment that mastering Vim requires taking the time to educate yourself on its shortcuts and functionalities. ![]() ![]() (Vim is a 1991 clone of Bill Joy’s vi editor created in 1976, to serve as the visual mode for a line editor called ex. Maybe it’s proof that the 50-year-old text editor has retained its popularity - that it’s now part of the shared collective experience of the developer community. A decade ago, a programmer asked on Stack Overflow how to exit the decades-old Vim open source text editor, and the question has since become a cultural touchstone of the modern development experience.
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |