this post was submitted on 26 Jun 2023
56 points (100.0% liked)

Linux

1259 readers
63 users here now

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

founded 5 years ago
MODERATORS
 

Helix does not aim to be a better vim / neovim. Thus, for example, there are officially no vim bindings and Helix follows the selection → action model. Helix is also a relatively new project.

https://github.com/helix-editor/helix/wiki/Differences-from

https://docs.helix-editor.com/title-page.html

top 22 comments
sorted by: hot top controversial new old
[–] nachtigall@feddit.de 13 points 1 year ago (2 children)

I recently gave it a try after seeing dessalines recommending it. It is pretty cool but years of vim muscle memory won’t go away so easily :D

[–] Fryboyter@discuss.tchncs.de 5 points 1 year ago* (last edited 1 year ago) (1 children)

In my opinion, users who already use vim are not the primary target audience of Helix. I see the target group more among users who want to switch from a "normal" editor to a modal editor. The selection → action model and the easier shortcuts probably make the switch easier for many. I personally don't like vim at all because of the handling (purely subjective view). Helix will definitely not be my default editor but I get along much better with it than with vim or neovim.

[–] KiranWells@pawb.social 6 points 1 year ago (2 children)

When I first tried Helix, my main concern (that prevented me from getting too far into it) was not going from Vim to Helix, but the other way around. Vim (or sometimes vi) is a standard editor on almost any Linux machine, so if I am ever working on a server if a VM, I would need to know/use Vim keybinds. That made Vim a more useful tool for me to learn at the time, as I could use the skills both on my machine and anywhere else.

[–] nachtigall@feddit.de 6 points 1 year ago (1 children)

I don’t feel like this is true anymore. Many distros do not ship vi(m) anymore but only nano.

[–] Kasion@lemmy.mackners.com 2 points 1 year ago (1 children)

Seems like most rpm based distro still ship vi/vim and don't default to nano.

[–] nachtigall@feddit.de 2 points 1 year ago

Good to know. In Debian and Gentoo nano is the only editor by default.

[–] Fryboyter@discuss.tchncs.de 1 points 1 year ago

Vim (or sometimes vi) is a standard editor on almost any Linux machine, so if I am ever working on a server if a VM, I would need to know/use Vim keybinds.

I understand the argument, but in my opinion it is used far too often and is not always true.

Not everyone works with servers on which they have no influence on the installed software.

And in the few cases where I had to work with servers on which I had no influence on the installed software and on which actually only vim was installed, I could always use sshfs or rclone mount without any problems so that the editor I used didn't matter.

[–] Kasion@lemmy.mackners.com 1 points 1 year ago

I agree, never understood why they changed a lot of basic shortcuts away from what vi/vim/neovim uses.

[–] natecox@lemmy.sdf.org 5 points 1 year ago

I am a fairly long time emacs user, used it as my primary editor and note taking app for around six years. I have a config large enough to warrant its own git repo separate from my normal dotfiles.

Before emacs I used vim for several years.

After really getting into Rust, I decided about three months ago to just take a look at helix and see what it was about… and I haven’t opened emacs or vim again since.

LSP and tree-sitter cover like 90% of what my old config was doing out of the box, and the kakoune inspired key bindings just felt so natural. I feel at home without the overhead of configuration paralysis.

Don’t get me wrong, helix has plenty of room to grow, but I’m excited to grow with it.

[–] SubArcticTundra@lemmy.ml 2 points 1 year ago (1 children)

I'm still a fan of turbo, Nano on steroids

[–] cole@lemmy.hugealligator.com 2 points 1 year ago (1 children)
[–] SubArcticTundra@lemmy.ml 1 points 1 year ago

Oh nice! Didn't know about this.

[–] zygo_histo_morpheus@programming.dev 2 points 1 year ago (1 children)

I sometimes play around with Helix and I almost always have a good time, but there are too many vim features that I have integrated in my workflow that there isn't any good equivalent to in Helix. I use ex commands, the quickfix list, snippets, the fugitive plugin and just little custom commands and mappings that I've accumulated. I don't see myself switching to any editor full time that doesn't have a replacement for most of these features, but Helix is very nice and fun to use occasionally.

[–] nous@programming.dev 1 points 1 year ago (1 children)

ex commands

Are these for scripting outside of vim (but using vim)? If so you can probably still use these with vim and helix for interactive editing. Unless I am misunderstanding what you mean by that feature.

quickfix list

<space>d (current file) and <space>D open a window of issues as reported by the current LSP which you can use to jump to the selected issue (with fuzzy filtering).

snippets

Looks like there is some basic support for lsp snippets which looks like you can add your own but a wider issue for better snippet support is being tracked here. So not ideal yet, but will hopefully improve over time.

fugitive plugin

It does have git gutter support and the :reset-diff-change command currently. And you can run git commands with :sh git ... though that experience could be improved. Staging changes is still pending here as is diffing changes here which look like there is work slowly being done on these.


So there are some workarounds for some of the things you need - and improvements being made to those that are missing. Might take some time for these areas to improve though and it depends on how you use those features as if/when things are good enough for your usecase.

There are many cases I actually prefer the quickfix list to an interactive picker:

  • When working on a very large project, such as my $DAYJOB, interactiveness gets in the way more than it helps if you're running a slow command (like greping a large number of files)
  • You can use :Cfilter to filter things matched in the quickfix list and :colder/:cnewer to navigate the history of the quickfix list without having to rerun the command
  • You can run ex commands on the items in the quickfix list, like :cdo norm gcc to comment the matched lines (with the vim-commentary plugin), run a macro with :cdo norm @q, or :cdo yank A to put all the matched lines in the a register for example. You can also do stuff like :cdo -10,+10g/re/p to print all lines matching some regular expression re within the range of 10 lines before to 10 lines after the match.
  • You can put more things in the quickfix list than you can with interactive pickers, like :Git diftool to get diffs. Vim also has support for parsing the output of many compilers and linting tools so you can use e.g. :compiler cargo followed by :make to build the current project with cargo and get any build errors in the quickfix list.

In short, interactive pickers are better for browsing, but the quickfix list is better for scipting and holding on to data for longer without having to rerun commands, and can with some basic scripting be used for more things.

Afaik helix doesn't have diff capabilities which is also a major thing missing from my git workflow.

I expect some of these things to make it into helix eventually, particularly git stuff, but I would be surprised if they add support for more weird janky vim stuff like the quickfix list and ex commands, which is a valid design decision, but they are also very useful tools once you get your head around them.

[–] dureuill@lemmyrs.org 2 points 1 year ago

I love the treesitter based movement (allows to move to beginning/end of a function), and the jump list (list of the locations where the cursor went, cross files and easy to navigate... Vscode really misses this).

I miss a debugging experience at least comparable to Vscode's with rust analyzer (ability to start the debugger on a single test case without having to look for the executable's path) to be able to use it day to day. To be honest, competing with vscode is always going to be difficult

[–] paccio 1 points 1 year ago

I'd love to try it, but I am accustomed to having always a terminal open in a pane in neovim. And I havent found an easy way to switch between helix pane and tmux/terminal emulator panes, like with the vim-tmux-navigator plugin

[–] mrmanager@lemmy.today 1 points 1 year ago

I want to like it but I just don't... I hate that it has words selected all the time, doesn't look clean and makes it all feel slower.

[–] pangyuehung@lemmy.ml 1 points 1 year ago

There's also Lapce which will hopefully implement Helix's editing model too: https://github.com/lapce/lapce/issues/281

load more comments
view more: next ›