Live data from Hacker News

Notes on switching to Helix from Vim

jvns.ca

181–190 of 242 posts

Re: Notes on switching to Helix from Vim

#181

I initially found the noun-verb model of Helix appealing, but I discovered that I prefer verb-noun much better after giving it a try. One major drawback of the noun-verb approach is its inability to support repetition using the `.` command, which is one of my favorite features in Vim. I often find myself doing something along the lines of `dd..`, `dap..`, ` ..`, or `/foo cgnbar ...un...`. More importantly, noun-verb…

Verb-noun changes how you think too. I believe it’s more in line with the mentality required to write code.

Re: Notes on switching to Helix from Vim

#182
post #136
post #111

Earlier quoted context omitted.

> presumably you would've been able to replicate it completely in the first X years of using vim, and then there is no hell anymore? I agree with this, but being able to ssh into a server and just grab Helix instead of copying over my Vim config and whatever else it depends on is really nice. Makes your dev env feel a lot more portable (although also more barebones than a crazy Vim config)

It's not like Helix is as ubiquitous as Vim on a random remote server. If that's not the case surely the effort to install Helix is bigger than copying Vim config?

I've had trouble in the past with systems whose version of vim is too old to understand the options in my config.

Re: Notes on switching to Helix from Vim

#183

Earlier quoted context omitted.

It might have been a bit harder in the past, but with recent versions of neovim (>=0.11) it's less than 20 lines of configuration. I have quite a few keybindings to jump back and forth through errors and the default keybidings already include things like renaming, go to definition or listing references. I'd be more than happy to help you configuring it to your needs.

FWIW, in my (emacs, C++) experience, writing the editor config is a relatively minor part of the yak-shaving required to have jump-to-definition on an actual work codebase. I had to get my project to emit compile_commands.json, get clangd, figure out which things about our build process clangd was not understanding from compile_commands.json and add them in .clangd. All to achieve a level of functionality significant…

    > I had to get my project to emit compile_commands.json,
    > get clangd, figure out which things about our build
    > process clangd was not understanding from 
    > compile_commands.json and add them in .clangd
That sounds rough. This is anecdotal, but in my Linux corner of the world, ccls has been an easier user experience as a C and C++ LSP since I've never had to resort to messing with flags in the generated file.

I haven't used clangd myself, though, so I can't say either way, I just know ccls works well.

By convention I tend to have the generated build system in build/ at the top-level of the repo so that the file is at build/compile_commands.json. That, or I'll arrange to have a symlink there pointing to one generated elsewhere.

The nvim snippet I use in my init.lua to setup ccls to work in that scenario is:

    vim.lsp.config('ccls', {
        init_options = {
            compilationDatabaseDirectory = 'build',
        },
    })
    vim.lsp.enable('ccls')
My actual config does also contain a capabilities = ... argument that forwards the default_capabilities() from nvim-cmp, but you get the point. I hope that helps in case you're curious to give neovim another spin.

Re: Notes on switching to Helix from Vim

#184
post #114

Earlier quoted context omitted.

I've been using Helix daily for about three years, and it has crashed about five times. It is very, very rare for it to SEGFAULT.

> every week or so there’s a segfault and the editor crashes.

The author of the OP appears to have edited it to indicate that it's just crashing, and doesn't know if it's a segfault or just a panic. It appears there is some known potential for segfaults in tree-sitter, which is a native C dependency.

Re: Notes on switching to Helix from Vim

#185
post #61

I cannot express how liberating it feels to opt out of "advanced" editor tools like lsp. I program in neovim with no plugins, no syntax highlighting and no autocomplete of any kind. There is a discipline that this imposes that I believe leads to better quality programs. It's not for everyone I suppose, but I really recommend trying it.

I haven’t made the jump yet but I believe you. My autocomplete has been broken on Emacs for a year, and I rarely miss it. I never use code actions, nor goto definition. I do enjoy real time errors but they often pop up with such a lag I’ve ran the compiler and it has shown me the error itself. So I dream of just turning off LSP — it’s not like it makes me such a better programmer than 20 years ago.

Re: syntax highlighting, I don’t know how people can work with their harlequin-on-LSD themes that are a constant distraction with no semantic benefit. I have gravitated around mostly mono or duochromatic themes, while 99% are a vomit of colours. I still don’t get why variables or function names need a distinct colour.

Re: Notes on switching to Helix from Vim

#186
post #177
post #56

Earlier quoted context omitted.

> Exactly! Pity this basic contextual help isn't more widespread, every single app that uses a lot of keybind sequences could benefit from it, especially if it becomes a bit smarter and only shows a popup if you don't finish the sequence right away I've been using Vim/Neovim for 20 years, but still can't get enough of which-key[1] which I only installed ~6 months ago. 1: https://github.com/folke/which-key.nvim

Yeah, that's the mortal sin of vim - insisting on shitty unergonomic defaults, requiring every new user waste time recreating a better UI while suffering for years before even the appropriate knowledge is acquired

I have not seen any unergonomic defaults in vim. Check your understanding of vim philosophy probably.

Re: Notes on switching to Helix from Vim

#187

Earlier quoted context omitted.

It’s true. Once you master Vim, your journey to find the perfect editor will have come to an end. For the rest of your career, you can rest assured you will be using some form of vim. But some people don’t actually want to find the perfect editor, they would rather stay on the journey forever, trying to master a new tool every few years. Sounds miserable, never knowing true mastery and enlightenment.

Where does evil-mode land?

From what I have heard, evil-mode does not give you an ability to touchtype, I mean totally blind typing without any pesky Escape Meta Alt Ctrl Shift chords.

Re: Notes on switching to Helix from Vim

#188

I never managed to understand Vim/Emacs/Vile/Neovim. Helix seemed all the same until I started watching a series of tutorials on Youtube. I get better everyday. I'm on Windows 10 x64 BTW

Vim and Emacs are too different to help you in one comment. At least you need to choose one of them by your own.

Re: Notes on switching to Helix from Vim

#189

Earlier quoted context omitted.

I recently found out that Mitchell Hashimoto has a setup like this, which blew apart my belief that you need modern tooling to be productive. Do you not find that you fatigue more quickly as a result of having to actively recall everything though? I can't understand how doing things like this would actually result in better code.

I'm not sure that's true. I've heard him talk in several interviews about using AI tools, including in his editor. Definitely not a minimalist setup.

See this interview: https://m.youtube.com/watch?v=v4qE1nzUidg&pp=0gcJCRsBo7VqN5t...

Re: Notes on switching to Helix from Vim

#190
post #177

Earlier quoted context omitted.

Yeah, that's the mortal sin of vim - insisting on shitty unergonomic defaults, requiring every new user waste time recreating a better UI while suffering for years before even the appropriate knowledge is acquired

I have not seen any unergonomic defaults in vim. Check your understanding of vim philosophy probably.

Check your understanding of ergonomics if you fail to see the obvious
Post reply on HN