TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

What Is Vim?

136 pointsby sauercrowd5 months ago

31 comments

chrismorgan5 months ago
&gt; <i>There&#x27;s a Vim mode in every single mainstream code editor out there.</i><p>And they’re always frustratingly incomplete and&#x2F;or buggy. Some motions will be unimplemented, or will behave incorrectly, especially with regards to boundaries around whitespace inclusion or exclusion in a motion. Things you added to Vim and got used to are unavailable, and so your <i>ysa&quot;)</i> to put parentheses around the string your cursor is on just doesn’t work. (Lack of vim-surround definitely gets me frequently.)<p>In VS Code, it maintains its own undo stack, and the interactions between the two undo stacks are terrible and terribly frustrating—yet doing without <i>might</i> be even worse, because they behave very differently.<p>And too often in a browser context, ^W will close your tab, losing data, rather then being inhibited and erasing the last word, as it should. That one is practically <i>unforgivable</i> in a Vim mode, yet common. That, more than anything else, will make me avoid a Vim mode.
评论 #42423566 未加载
评论 #42421455 未加载
评论 #42421351 未加载
评论 #42424383 未加载
评论 #42424091 未加载
评论 #42421539 未加载
评论 #42422813 未加载
评论 #42421197 未加载
评论 #42425538 未加载
评论 #42421549 未加载
评论 #42424605 未加载
评论 #42421349 未加载
评论 #42424004 未加载
评论 #42424094 未加载
kazinator5 months ago
Vim is not only an editing language, but a fast-starting editor with a small-ish native executable, and small run-time memory use.<p>This facet is typically not ported into other editors that have a Vim mode.<p>Vim runs natively inside virtual machines and containers, on resource-constrained embedded systems, and on remotely accessed machines.<p>Another aspect is that Vim can be operated entirely using a terminal emulator, and so can be running on a remote host to which the use only has a SSH or serial connection.
评论 #42424223 未加载
评论 #42424332 未加载
评论 #42424451 未加载
评论 #42425971 未加载
评论 #42425757 未加载
评论 #42427029 未加载
评论 #42424620 未加载
mmahemoff5 months ago
Learning Vim early on had a high return on investment for this reason. Years later, I&#x27;m still able to benefit from the same muscle memory in modern tools, e.g. Obsidian.<p>It should be said, though, that most implementations are simplified rewrites of Vim&#x27;s core functionality. When you use a tool to achieve a sense of &quot;flow&quot;, it can be grating for the editor to behave in subtly different ways from expectation, or discover an important feature does not work at all. Also, there tends to be limited, if any, support for Vim plugins.<p>In the modern era of Vim and NeoVim, it&#x27;s possible for such tools to use the real version via network protocol, but integration is easier said than done. So far it&#x27;s mostly been Vim GUI wrappers that leverage the capability rather than independent editors.<p>I still use Vim mode where I can even if it&#x27;s a shadow of the real Vim experience. It makes life easier to use the same muscle memory on every shell, editor, and command-line, and not have to worry about learning every new app&#x27;s idiosyncracies.
评论 #42421170 未加载
lambda_lord5 months ago
Helix uses a selection-first action model: you select the word&#x2F;paragraph&#x2F;whatever you want to perform an action on, then you change&#x2F;delete&#x2F;whatever on that selection.<p>I think this is more intuitive than the &quot;verb object&quot; model Vim uses: if you get your selection wrong in Vim, you then need to undo the action and try again. In Helix, I can see what I am about to manipulate before I make the action.<p>I think at this point Vim wins out for being so ubiquitous, but I wish the Helix model took off first.
评论 #42423267 未加载
评论 #42421135 未加载
评论 #42421165 未加载
评论 #42421209 未加载
评论 #42421146 未加载
评论 #42424467 未加载
评论 #42422949 未加载
评论 #42421102 未加载
评论 #42421557 未加载
alienchow5 months ago
Vim is this editor that a senior backend engineer told me to go try for a week, when I was still relatively junior. Like really try to remember all the shortcuts, not some half-assed attempt then laugh about not being able to remember &lt;esc&gt;:wq. If I were able to demonstrate fluent Vim skills at the end of the week, he&#x27;d gift me his TKL mechanical keyboard with a Vim keycap on the escape button.<p>It&#x27;s been 9 years since that challenge, and I&#x27;m still typing on the Filco keyboard. Good memories. Although I&#x27;ve since moved on to NeoVim for the LSPs. It&#x27;s nice that I can freely edit files on any machine for something I picked up in a week.
lproven5 months ago
I think this is a classic example of Unix-induced tunnel vision.<p>Because Vi[m] is just one example of a keyboard-driven UI that has been adopted in other places, whereas in fact there&#x27;s a more common one that&#x27;s used by more people on more computers every day... but it&#x27;s not widely known that it&#x27;s a thing and it has a name.<p>It&#x27;s IBM CUA.<p><a href="https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;IBM_Common_User_Access" rel="nofollow">https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;IBM_Common_User_Access</a><p>It is what defines the keyboard interface of MS Windows, and tens of millions of skilled Windows users use parts of CUA every day, from Alt+F4 to close a window to Ctrl+S to save to Ctrl+F to find to F2 to edit.<p>For blind and visually impaired users it is the sole or primary UI for Windows.<p>It is also largely supported in multiple Linux and FOSS desktops, such as Xfce, Unity, LXDE, LXQt, MATE, and others.<p>Sadly, KDE does not implement much of it, and modern GNOME almost none of it.<p>But it&#x27;s there and most Gtk desktop apps support some of it -- although Gtk4 is driving that out now.<p>CUA provides a whole set of consistent keyboard controls for DOS, Windows 3.x, 9x, NT, 2000-11, OS&#x2F;2, and almost all the Linux desktops until GNOME 3 came along. It has editing keys but also far more.<p>A skilled person can drive all of a Windows computer, and all apps, as quickly as a skilled Vi[m] user can -- well, can edit text and nothing else.
slightwinder5 months ago
&gt; There&#x27;s a Vim mode in every single mainstream code editor out there.<p>Is it really a vim-mode, or a vi-mode? I mean, most of those are already very limited, but does any of them actually support vim-specific evolutions&#x2F;changes?<p>And isn&#x27;t the real question here: where does generic modal editing end, and when does vi(m) starts to display its specific personality?
AdieuToLogic5 months ago
Vim is efficient, in that there is no need for one&#x27;s hands to leave the keyboard.<p>Vim is succinct, in that what is needed often takes less commands than those less frequent.<p>Vim is pliable, in that can be made to do whatever you wish.<p>Vim is everything, vim is nothing.<p>Mastering vim is to find Zen made possible by an exponential command space.
danielvaughn5 months ago
I’ve yet to get sucked into Vim, though I’ve given it a shot on a few occasions. I just feel too much muscle memory with whatever you call normal editing. One of these days I want to really stick with it because I do love the verb&#x2F;action&#x2F;modifier idea. I’m even building a similar keyboard-driven editor for building UIs. It has commands like “s a i” (select all images), “a t n” (add text element as next sibling), etc.
评论 #42421372 未加载
stevebmark5 months ago
Agree that Vim is a language to talk to your computer, but it&#x27;s not necessarily efficient. Vim is famously an imperative editor: You have to tell Vim the sequence of steps to perform. Clicking your mouse on a position on the screen is declarative: You declare you want the cursor here. With Vim you have to imperatively walk the cursor to where you want to go, or god forbid use something like easymotion.
评论 #42421240 未加载
评论 #42421214 未加载
评论 #42421611 未加载
评论 #42422854 未加载
评论 #42424042 未加载
评论 #42422835 未加载
评论 #42421174 未加载
sexyman485 months ago
<i>imagine you would remove the functionality that Vim mode in VSCode gives you from Neovim.</i><p>imagine you what?
评论 #42424274 未加载
ggm5 months ago
Even though I wince at mis remembered muscle memory using it, I still wish nvi had progressed a little further. I mostly turn off vim features. Default cut-paste with code indent is a giant mismatch. It&#x27;s cruder, and itself a mishmash of non-joy code, but I found nvi suited me well for decades on netbsd and freebsd, and I use it still. I do run the port on osx but somehow each upgrade I find myself slipped back into vim. And on debian and the like.<p>I live in Emacs for org, and vi for code edit. Happy mix these last 40+ years.<p>Sometimes it&#x27;s hard to recall that ex exists, inside vi. But if you do any :command that&#x27;s where you are. Inside a simpler editor landscape embedded in the visual world.<p>Ed is a sometimes tool. Always gratifying to use it!
wycy5 months ago
Learning vim was one of the best things I did for myself at work. Completely changed everything about the way I work and made me so much faster.
hashkb5 months ago
I love this take. I was a die-hard Vim&#x2F;Neovim zealot... but these days I absolutely love the ecosystem of tools that support normal mode. For so long hand-cramping emacs keybindings were sort-of-standard-in-a-few-places.<p>If you&#x27;re not convinced vimming is the best way to interact with your editor, you probably haven&#x27;t seen a really proficient vimmer.
评论 #42422874 未加载
syndicatedjelly5 months ago
I recently gave up on VSCode because the Vim mode is still substandard, missing keybindings, and constantly glitches out in new and fun (read: not-fun) ways. I’m just gonna use NeoVim and program the IDE myself, in a true moment of going super-saiyan as a programmer
smusamashah5 months ago
How do you explain &quot;w&quot; and &quot;wq&quot; to save and quit the editor with &quot;verb adjective object&quot; model?<p>These two and &quot;i&quot; is all I remember about vi. Or is vi a different thing from vim and this model doesn&#x27;t apply?
评论 #42422028 未加载
评论 #42422849 未加载
favflam5 months ago
Is anyone here using Lazyvim? I switched to this from VS code and it feels much more productive and lightweight on my computer.<p>I never got into VIM before until I saw some Youtube personality using Lazyvim.
eonmist5 months ago
To me there was a distinct &quot;aha&quot; moment when the &quot;vim language&quot; suddenly made sense. Makes me think of when kids suddenly discover how to read.
linsomniac5 months ago
I was in a PyCon presentation about the Python bytecode when I came up with the idea that vim editing commands are a bytecode for executing text manipulation.
beacon2945 months ago
I&#x27;ve been using vscode in java because of the cumbersome file navigation in bash. Is there easy full tree navigation in vim?<p>It may also be because the terminal view is much smaller than vscode&#x27;s smaller navigation font so I can see much less of the file tree in a terminal program such as ranger.<p>I also never really mastered windows although I did master vim buffers.<p>I do use tmux.
评论 #42429030 未加载
j7ake5 months ago
&gt; There&#x27;s a Vim mode in every single mainstream code editor out there<p>Not Jupyter notebooks though (by default)
h43z5 months ago
My ode to why speed even matters <a href="https:&#x2F;&#x2F;h.43z.one&#x2F;vimsteps&#x2F;0" rel="nofollow">https:&#x2F;&#x2F;h.43z.one&#x2F;vimsteps&#x2F;0</a>
FpUser5 months ago
&gt;&quot;Wha Is Vim&quot;<p>Something I&#x27;ve never learned. Not proud of it but I do not think I am missing anything either. I write native software for Linux for living at the moment.
评论 #42421286 未加载
评论 #42422904 未加载
评论 #42421243 未加载
delta_p_delta_x5 months ago
I am too stupid for Vim. The bottleneck is my brain, not my typing speed.
评论 #42425737 未加载
gorfian_robot5 months ago
vi is fine. never seen the need to get all fancy with vim.
评论 #42424173 未加载
p0w3n3d5 months ago
vim is an operating system that allows also editing files
评论 #42426258 未加载
dallbee5 months ago
Cho 55
cassepipe5 months ago
Yet another article about vim that does not mention remapping Escape even though it&#x27;s a dumb historical accident that the most important key is the furthest away from the home row.
cutler5 months ago
&quot;Vell Vim&#x27;s just zis guy, you know&quot;
评论 #42422868 未加载
评论 #42432988 未加载
tom_5 months ago
I guess. Wake me up when you can enable Emacs mode in vim.
评论 #42421055 未加载
评论 #42421194 未加载
steve19775 months ago
Article mainly seems to talk about vi, not vim. But I guess the author doesn&#x27;t know where vim is coming from.
评论 #42424842 未加载