cross-posted from: https://lemmy.ml/post/9648279

I would like to premise this with the following:

  • The best approach is probably just testing out each and every editor that interests me until I’ve found what works best for me.
    • However, I wonder to what degree a test as such would be representative when the likes of Emacs and (Neo)Vim are considered; both of which are known for being a life time learning process.
  • I don’t literally expect Emacs or (Neo)Vim to be drop-in replacements for any IDE. Some of the most basic IDE-functions are absent by default and some (perhaps more advanced) functionality might simply not be attainable at all.
  • I am not interested in anything that remotely resembles a flame war. The community at Lemmy has so far been very kind to me; let’s keep it that way 😜.

Motivation

I’ve had experiences with Atom, VS Code and some of Jetbrains’ IDEs like Pycharm and Rider. While I’ve been generally content with all of them, it leaves a bad taste in my mouth whenever I’m forced to switch IDEs because their lifetimes and/or lack of extensibility doesn’t allow me to responsibly continue using them. As such, I’m interested in a long time investment that will grow as I will. Both Emacs and (Neo)Vim have passed the test of time and I honestly don’t think they’ll cease to exist in the upcoming decades, that’s why I would love to start using either one of them.

Furthermore, Vi(m) keybindings seem to be somewhat ubiquitous and almost any IDE offers some support. As such, improving my Vi(m)-game should only net-positive my productivity (at least eventually). Also, fluency will benefit me whenever I’m remote accessing any random server as they will always have Vi(m) installed. Thankfully, this doesn’t force me to use Vi(m) (or Neovim) just yet, because Emacs offers with Evil perhaps the single best Vi(m) implementation; outside of native Vi(m)*.

My setup:

  • I’m on a custom image of uBlue using their startingpoint as template. For those unaware; an oversimplification would be that it is Fedora Silverblue with some extras.
  • As such, I would like to have my developer environments local and have used Distrobox to that extent using steps similar to the ones outlined over here. But I’m not married to that specific way of utilizing local containers. So please feel free to recommend me something that’s at least as good.
  • If I go for Emacs, then I will definitely rely on Evil.
  • If possible, I would like to use it for C#, Python and Rust. Furthermore, I engage in editing Bash scripts, Dockerfiles, Linux config files, texts written in Latex and/or Markdown and other files written in Nix or JSON. As both are very extensible, I don’t expect any issues, but I might be wrong.

Questions:

  • First of all, does it make sense for me to only consider these two?
  • Can the split between Vim and Neovim be interpreted as the first schism and as such be a forebode for what’s yet to come?
  • Google Trends suggests that Neo(Vim) is ever-popular. On the other hand; not only is Emacs relatively less popular, but its popularity seems to be slightly declining. Should this worry me regarding their long-time future? Especially considering that a thriving community is literally the lifeline for both of them.
  • For those that have used both extensively, which one do you prefer (if any) and why?
  • While I understand that the power of both of them lies primarily in how one can literally make them behave however suits their workflow best. Therefore, the use of premade configs and/or starter kits/distributions should (ideally) only be used either temporary or as a starting point. However, at this point, they provide a decent showcase of what each ‘platform’ has to offer. So:
19 points

I have used vim/neovim for years and cannot go back to a non-modal editor. But TBH I got sick of its configuration. You need far too many plugins and config to get things into a sane working order to be usable on a day to day bases for any type of development. It takes ages to learn and become as productive as you were before and a lifetime to refine.

For the past year or so I have switched to helix and don’t plan on going back to vim/neovim as my main editor ever again. It is a modal editor that is a mix between Neovim and Kakoune editors. It comes with batteries included, and supports an IDE like experience out the box with treesitter syntax highlighting and LSP language integrations out the box. My whole config is like 6 lines long yet it works far better then my old neovim setup with a multitude of plugins and hundreds of lines of config. It is like what AstroNvim, LazyVim, LunarVim and NvChad etc are trying to do to vim/neovim but instead has built in support for all the things they rely on plugins for. Which means there is no need to constantly keep them up to date nor weird edge cases where one plugin does quite integrate with another smoothly. It is all built in so things are designed to work well together.

But it currently does lack any plugin support. So if something is not built in that you want you have to make due without it (well, except language support, adding new LSPs is not too hard). And plugin support is being worked on so even this will be a non-issue hopefully in a year or two.

permalink
report
reply
4 points

I have used vim/neovim for years and cannot go back to a non-modal editor. But TBH I got sick of its configuration. You need far too many plugins and config to get things into a sane working order to be usable on a day to day bases for any type of development. It takes ages to learn and become as productive as you were before and a lifetime to refine.

Interesting. Though I can definitely see where you’re coming from. Uhmm…, have you used any of the Neovim distributions to make maintenance easier?

For the past year or so I have switched to helix and don’t plan on going back to vim/neovim as my main editor ever again.

Both Helix and Lapce have certainly piqued my interest as FOSS alternatives to VS Code. However, both have issues related to how well their current Vi(m) implementation is. As you’ve touched upon it; Helix’ keybindings and ‘sentence-structures’ are different to those found on Vi(m).

Furthermore, neither of the two have existed long enough to be able to profess any statement regarding their longevity. Like, there’s no guarantee that I can keep using either of the two 20 years into the future. While no program is able to 100% guarantee that, undoubtedly, the track records for both Emacs and Vi(m) testify that -if anything- they would be the most likely ones to survive 20 years down the line; like how they’ve done for the last couple of decades.

I appreciate the input, but I simply don’t want to invest in a program whose future is very unclear to me at this point in time.

permalink
report
parent
reply
6 points

Interesting. Though I can definitely see where you’re coming from. Uhmm…, have you used any of the Neovim distributions to make maintenance easier?

I have, but dont like them. They all have weird install processes and need to manage their own set of configs on top of vim in your home dir. This makes them very hard to properly package or integrate with config management tools and require a different flow to keep them up to date from the rest of your system. They combine sometimes hundreds of plugins, of which only a few are designed to work together and while a lot don’t try to step on each others toes that many I often find issues in niche use cases. And when you do find an issue, or something you want to tweak you have 100s of plugin configurations that you need to learn about to figure out just what is doing what and which options you need to tweak.

It is all just far more hassle then I want out of my editor these days. Helix just works out the box and has basically everything I want from a editor nicely integrated into it.

As you’ve touched upon it; Helix’ keybindings and ‘sentence-structures’ are different to those found on Vi(m).

They are a little different and take a bit to get used to. But IMO I find them far nicer way to work. It is very nice being able to see what your action is going to effect before you do it - unlike in vim when you just hope you have hit the right movement keys. And it also pops up a small window for leader keys (like space) which show you what you can do with it making it far more discoverable then vim/neovim without needing to pour though hundreds of pages of manuals to even get a glimpse of what it can do or needing to go back to them to remember something that you dont use very often. It is not trying to be a 100% vim compatible layer, it is trying to give you the best experience it can out the box. And I think it does that quite well (at least once you get used to the new way of working - which does not take that long).

Furthermore, neither of the two have existed long enough to be able to profess any statement regarding their longevity. Like, there’s no guarantee that I can keep using either of the two 20 years into the future.

20 years is a long time. I can see it existing for the next 5 years at least, and looks to be on the trajectory to be a long lasting product. Though no one can say for sure. But, the more people using it the more likely it is to stick around for the long term. Just about everyone that I have seen use it over vim have highly praised it and it has quite a few contributors already (700+ on github), which is very impressive compared to vim (about 300), and neovim (more then 1100).

And keep in mind that vim has been around so long thanks to a single maintainer, Bram Moolenaar, who passed away this year. Which is not a great sign for vims future for the next 20 years.

I appreciate the input, but I simply don’t want to invest in a program whose future is very unclear to me at this point in time.

The investment in helix is far less then that you need to put into vim/neovim due to all the configuration you need for them. Well worth it for how active it currently is and how many people are putting effort into it.

permalink
report
parent
reply
1 point

Wow! Excellent and thorough response. Thank you so much for taking your time 😊!

It is very nice being able to see what your action is going to effect before you do it - unlike in vim when you just hope you have hit the right movement keys.

That’s awesome! Which does beg the question why the others haven’t implemented such functionality (yet)?

And it also pops up a small window for leader keys (like space) which show you what you can do with it making it far more discoverable then vim/neovim without needing to pour though hundreds of pages of manuals to even get a glimpse of what it can do or needing to go back to them to remember something that you dont use very often.

Interesting. If I’m not mistaken, both Spacemacs and Doom Emacs offer similar functionality through the emacs-which-key package. I would think that Neovim should have some plugin that does something similar, but perhaps not.

Just about everyone that I have seen use it over vim have highly praised it and it has quite a few contributors already (700+ on github), which is very impressive compared to vim (about 300), and neovim (more then 1100).

I didn’t expect for them to be so many 😜. Hmm…, food for thought; thanks for pointing that out!

And keep in mind that vim has been around so long thanks to a single maintainer, Bram Moolenaar, who passed away this year. Which is not a great sign for vims future for the next 20 years.

I definitely understand that Vim’s future is lot less certain compared to two years ago due to the passing of Bram Moolenaar. However, and I might be wrong on this, but I feel as if Vim has reached a critical mass of following such that it’ll probably continue to exist in some healthy form regardless.

In general I think you make a excellent case for Helix. I’m actually considering if I should reconsider it (if that makes sense). Uhmm…, but two questions remain:

  • I shouldn’t expect remote accessing some random server will allow me to use Helix, right? Is there any other way to make this work? Or…, should I just learn both Vim and Helix’ Vim + Kakoune amalgamation?
  • Vim is literally ubiquitous and plugins that enable its features can be found on almost any ‘platform’. It’s unrealistic to expect Helix’ adoption to be at that rate (yet). However, would you happen to know if at least the likes of VS Code and/or Jetbrains’ IDEs support it? And if so, how good their support/implementation is?
permalink
report
parent
reply
6 points

As you’ve touched upon it; Helix’ keybindings and ‘sentence-structures’ are different to those found on Vi(m).

Unless you really want vim bindings, try them out. At least Helix is based on the Kakoune editing model which is the editor I use, and I much prefer the way Kakoune works over vim, while still being close enough so that you can pick it up quickly if you already know vim and the other way around.

permalink
report
parent
reply
4 points

Unless you really want vim bindings

I kinda do for how ubiquitous Vim keybindings are.

try them out.

Regardless, I think I will try it out after I’m at least somewhat productive with Vim.

I much prefer the way Kakoune works over vim

I think preference is generally subjective. So you’re completely in your right to prefer Kakoune over Vim (and vice versa). Though, if possible, would you mind elaborating what you prefer exactly and why?

while still being close enough so that you can pick it up quickly if you already know vim and the other way around.

Doesn’t that disrupt muscle memory?

permalink
report
parent
reply
1 point
Deleted by creator
permalink
report
parent
reply
10 points
*

I’m sorry, which editor allows you to exit easily with escape colon q bang enter?

Uh huh. That’s what I thought.

permalink
report
reply
1 point

You have to hit esc several times though. Just to be sure.

permalink
report
parent
reply
7 points
*

Hi. I’ve briefly shared my experience with neo(vim) and emacs here. Going into all the details would require writing an encyclopedia because they’re both so vast topics. I think the main factor of choice would be to know if you prefer to build your own perfect tool with just what you need and expand as you go (i.e. neovim) or just have a do-it-all ready tool right out of the box (i.e. emacs). Both will require some coding and maintenance anyway. In that regards, I personaly found neovim to be easier and more reliable but mileage may vary based on your needs and preferences. After years using vim 20 years ago, I made a break. Then I used emacs for a year before eventually going back to neovim. I would certainly recommend it vs vim and I would suggest starting from scratch (no lazyvim or similar) so you clearly understand how things work. This will certainly be useful in the long run anyway and that’ll eventually save you time. Note that I’ve also tried welcome screens (startup) but really couldn’t justify its use so I removed it after few months.

permalink
report
reply
1 point

Hi!

I’ve briefly shared my experience with neo(vim) and emacs here.

Thanks for sharing that! I’ve just read through it and it was a very interesting read. Would you mind elaborating upon the following statement?

“the lack of uniformity across plugins coding which sometimes created some conflicts”

I think the main factor of choice would be to know if you prefer to build your own perfect tool with just what you need and expand as you go (i.e. neovim) or just have a do-it-all ready tool right out of the box (i.e. emacs).

That is indeed something that concerns me regarding Emacs. Like being able to surf on the internet or using it as a email client isn’t quite what I expect out of my IDE 😅. I guess the extensibility should allow ‘minimal’ installations, but this is something I should read more into. Thanks for pointing that out!

permalink
report
parent
reply
1 point

My statement about the lack of uniformity was in regards to several issues I had with some plugins in emacs. Even my friend who codes his own plugins for emacs was of no help because 1) there is too many approaches and dependencies to write plugins, 2) there was no solution. Also, there are too many plugins to serve the same purpose and I found it difficult (compared to neovim) to figure out the difference between them. At least twice I also experienced conflicts between plugins. Finally, the level of customization was also less granular than what offers neovim. Again, I can see why emacs is appealing to some. It’s just not for me. As I like to say, the number of options available in the Linux world is one of the most beautiful things that makes this OS the only one you can tweak perfectly to any user’s needs and preference.

I would add that neovim and emacs both have a steep learning curve but I personaly found the level of support and core and plugins documentation for neovim more accessible, readable, and better organized.

I completely share your vision about what an IDE should be doing. I’m old school and adhere to the “do one thing but do it right” philosophy. Also, I hate relying on one tool for several needs because if anything goes wrong it has multiple impacts. As a side note, I use neomutt as my email client and you can nicely couple neovim to it to write your emails ;)

permalink
report
parent
reply
1 point

I appreciate your input. Thank you!

Also, there are too many plugins to serve the same purpose and I found it difficult (compared to neovim) to figure out the difference between them.

Interesting.

Finally, the level of customization was also less granular than what offers neovim.

Very interesting. I’d love to hear more about this. Could you elaborate?

I would add that neovim and emacs both have a steep learning curve but I personaly found the level of support and core and plugins documentation for neovim more accessible, readable, and better organized.

I wouldn’t be surprised if this is in part attributable to the fact that Emacs is both an older project and is generally-speaking a bigger and/or more capable piece of software.

I completely share your vision about what an IDE should be doing. I’m old school and adhere to the “do one thing but do it right” philosophy. Also, I hate relying on one tool for several needs because if anything goes wrong it has multiple impacts.

I’ve often heard Emacs users pose the argument that Emacs as an Elisp interpreter does just one thing. It’s just that this single thing allows the myriad of functionality it offers. So in that sense comparing it to a terminal/console seems more apt than comparing it to a text editor. I wonder what you think of that argument.

As a side note, I use neomutt as my email client and you can nicely couple neovim to it to write your emails ;)

Hehe, that’s cool! Currently I’m really happy with Thunderbird so I don’t expect to move away anytime soon, but I’ll keep it in mind.

permalink
report
parent
reply
5 points

I’m actually using nvim for rust development and it’s really fucking great but I’ve been using vi for like 25 years so for me the only issue was configuration, the editor is just natural for me. If you also have to learn the editor I don’t know what your experience will be.

As for configuring it for development I started with spacevim and managed with half the functionality normal IDE provides for quite some time. The experience was still good. About 6 months ago I set up nvim and now I have everything I need. I think setting up nvim for rust was as complicated as setting up spacevim. Spacevim provides way more out of the box but changing configuration is not easy at all.

I don’t worry about vim/nvim “schism”. The support is still great.

I would say just go with nvim, spend a week to set it up and don’t get too obsessive if small things don’t work. Enjoy the amazing responsiveness and great editor and you will figure out everything eventually. And if you have any questions just ask. I can share my config.

permalink
report
reply
1 point

As for configuring it for development I started with spacevim and managed with half the functionality normal IDE provides for quite some time. The experience was still good. About 6 months ago I set up nvim and now I have everything I need. I think setting up nvim for rust was as complicated as setting up spacevim. Spacevim provides way more out of the box but changing configuration is not easy at all.

Would it be fair to assume that the switch from SpaceVim to Neovim was due to how difficult changing its configuration was to better suit your needs? Would you say this is SpaceVim’s fault? Or rather Vimscript is to be blamed?

I don’t worry about vim/nvim “schism”. The support is still great.

I also meant it in the sense that perhaps later down the line something else will come out to ‘replace’/‘improve’ upon Neovim. Until -in turn- that one is one day replaced as well and so on and so forth… Like, we’ve already gone from Vi -> Vim -> Neovim. While, on the other hand, Emacs still is Emacs. Thankfully, the modal editing part of Vim should persevere regardless; even if the name of the editor changes every so often.

I would say just go with nvim, spend a week to set it up and don’t get too obsessive if small things don’t work. Enjoy the amazing responsiveness and great editor and you will figure out everything eventually. And if you have any questions just ask. I can share my config.

Thank you for the encouragement! At this point, I intend to start with Vi(m) to get used to the core experience.

permalink
report
parent
reply
2 points

The problem with SpaceVim is that it offers a lot of toggles that are easy to switch but there are no examples for more ‘custom’ config and I struggled to figure it out. There’s a lot of examples and guides for nvim so it was easier. I don’t know, maybe it was just me but with SpaceVim I also didn’t really see what’s possible. With nvim I just found long lists of useful plugins that you can add one by one.

As for the future I don’t really worry that there will be next thing after neovim. I didn’t write any custom scripts for it, all I have is just plugins with mostly default settings. It would take me a day to switch to another tool witch is not a big issue.

I think starting with Vim is a good idea. You can easily add plugins one by one when you will see the need for them.

permalink
report
parent
reply
1 point
*

The problem with SpaceVim is that it offers a lot of toggles that are easy to switch but there are no examples for more ‘custom’ config and I struggled to figure it out. There’s a lot of examples and guides for nvim so it was easier. I don’t know, maybe it was just me but with SpaceVim I also didn’t really see what’s possible. With nvim I just found long lists of useful plugins that you can add one by one.

Makes a lot of sense. Documentation is indeed very important. Thank you so much for sharing your insights and experiences! Much appreciated!

permalink
report
parent
reply
5 points

Nvim is more optimised, while emacs is more extensible. Basically you can modify core parts of emacs while it runs. I tend to use both, depending on the situation, with a lighter nvim config. Sometimes the 3 second emacs startup time is annoying so I use vim then. I think its fine to try both.

Regarding emacs declining popularity, I think that in the long term it could be a problem, since most people don’t want to learn elisp just to configure their editor. Elisp is very powerful in emacs, but its design is very different to other languages, so as emacs contributors get older, it could possibly lead to less and less new contributors.

Idk about the vim distros, but I think Doom Emacs is easier for beginners to get into.

permalink
report
reply
2 points

I tend to use both, depending on the situation, with a lighter nvim config. Sometimes the 3 second emacs startup time is annoying so I use vim then. I think its fine to try both.

Could you elaborate more upon your workflow? Like, in which situation do you prefer Emacs and when do you prefer Neovim? I get that the lighter option is preferred when you want to perform a quick edit or can’t be bothered with startup time. But I want to know it beyond that and -if possible- what led you to favor one over the other in each situation.

Regarding emacs declining popularity, I think that in the long term it could be a problem, since most people don’t want to learn elisp just to configure their editor. Elisp is very powerful in emacs, but its design is very different to other languages, so as emacs contributors get older, it could possibly lead to less and less new contributors.

How do you envision Emacs’ future? Would, at some moment in the future, some kind of compatibility layer of sorts be developed that lower the entrance barrier? To my knowledge, Emacs has -contrary to Vim- been more open to community development. So I don’t expect something like NeoVim to be developed for Emacs as there’s less need for it. But I don’t know how much they’d be willing to change Emacs for the sake of making it more attractive for new users.

Idk about the vim distros, but I think Doom Emacs is easier for beginners to get into.

Compared to Spacemacs I assume*. If so, would you mind elaborating?

permalink
report
parent
reply
2 points

I’m not using lsp in Neovim so if I need lsp I’ll just pull out emacs. If I’m already in the terminal I’ll usually pull out Neovim to edit a file, but if I’m writing like markdown or something that uses images I like the ability to display images inline in emacs. LaTeX is always something I do in emacs because there’s a built in pdf viewer in emacs and there’s built in spell check also. In the terminal in emacs, sometimes I open up Neovim to do a quick edit because of muscle memory from the terminal. One thing that’s really cool about Neovim is that you can embed it in other applications, so if I really have to use an ide that’s not emacs, I’ll just do that.

I don’t use Neovim for complex tasks, because personally I find it a bit hard to discover commands compared to emacs. The menubar in emacs is really useful for finding useful commands in different major and minor modes.

Yeah there’s a thing called EAF, which allows python and javascript to be embedded in emacs. It allows for more complex applications to be built in emacs, similar to VSCode. I’m not sure how difficult it is to make something with EAF, but I haven’t really seen any things written in it that aren’t in the EAF organization. I think the future could be EAF or maybe something like EAF to be able to leverage the power of the javascript ecosystem like how VSCode does for a lot of plugins. There have been some attempts to rewrite emacs in different languages, but emacs is too large, and you would lose the old ecosystem by doing that.

There’s a larger community around Doom Emacs, and Doom Emacs looks nicer. Honestly though it doesn’t matter that much which one you use since they are both pretty good.

permalink
report
parent
reply
2 points

I’m not using lsp in Neovim so if I need lsp I’ll just pull out emacs. If I’m already in the terminal I’ll usually pull out Neovim to edit a file, but if I’m writing like markdown or something that uses images I like the ability to display images inline in emacs. LaTeX is always something I do in emacs because there’s a built in pdf viewer in emacs and there’s built in spell check also. In the terminal in emacs, sometimes I open up Neovim to do a quick edit because of muscle memory from the terminal. One thing that’s really cool about Neovim is that you can embed it in other applications, so if I really have to use an ide that’s not emacs, I’ll just do that.

Wow, the insights! *Vehemently noting these down somewhere* Heck, I think you’ve cracked the code. Since I’ve created these posts, I became more and more aware of how great both Emacs and (Neo)Vim are. And while I was already flirting with the idea to perhaps use both, I think you’ve just completely obliterated any other option; which is a good thing. As such, I’m actually grasping for words that would somehow be able to properly convey the feelings of gratitude I currently experience. For whatever it’s worth; thank you from the bottom of my heart!

Yeah there’s a thing called EAF, which allows python and javascript to be embedded in emacs. It allows for more complex applications to be built in emacs, similar to VSCode. I’m not sure how difficult it is to make something with EAF, but I haven’t really seen any things written in it that aren’t in the EAF organization. I think the future could be EAF or maybe something like EAF to be able to leverage the power of the javascript ecosystem like how VSCode does for a lot of plugins. There have been some attempts to rewrite emacs in different languages, but emacs is too large, and you would lose the old ecosystem by doing that.

Once more; much appreciated!

There’s a larger community around Doom Emacs, and Doom Emacs looks nicer. Honestly though it doesn’t matter that much which one you use since they are both pretty good.

Yet again; I’m grateful! Have a good one! I wish you and your loved ones the best!

permalink
report
parent
reply

Sometimes the 3 second emacs startup time is annoying so I use vim then.

The way I get around this is by using emacs in daemon mode. So it only has a long startup if I’ve just rebooted my computer or if I needed to change my config and manually restart emacs. You probably already know emacs can run as a daemon, but I thought I’d mention it anyway!

permalink
report
parent
reply

Linux

!linux@lemmy.ml

Create post

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

  • Posts must be relevant to operating systems running the Linux kernel. GNU/Linux or otherwise.
  • No misinformation
  • No NSFW content
  • No hate speech, bigotry, etc

Related Communities

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

Community stats

  • 7.2K

    Monthly active users

  • 6.6K

    Posts

  • 179K

    Comments