I’ve tried vim on and off during college but never really had the time to fully get working with it. As it turns out the stress of two degrees is not conducive to “fun activities”. Now that I have a real job ™️, I’ve decided to finally try and use it this week full stop and I genuinely feel like a programming chad. There’s still a lot I’ll need to learn and probably overtime I’ll discover some inefficiency in how I’m using it now but it really does just feel good. I understand the hype now.

  • Mr. Satan@lemmy.zip
    link
    fedilink
    arrow-up
    1
    ·
    4 days ago

    So I keep trying vim and now neovim, I kind of like it as a good allrounder for one off syntax highlighted editing. It’s just that for me, quick and simple editor.

    For a true IDE I need proper symbol navigation. What I have in my JetBrains setup: ctrl+click - go to definition, ctrl+shift+click - search for references, alt+ctrl+click - go to implementation, alt+ctrl+shift+click go to declaration (specific to going to an interface). Then there’s symbol renaming and good multi carret / selection support with keyboard and mouse bindings (alt+up/down arrows, alt+single/double/tripple click). Also, multicarret copy pasting is a major feature.

    Let’s not forget about live static analysis and autocomplete with support for fuzzy search and documentation.

    I don’t even know where to start to make vim or neovim do all that. If it can’t do that seamlessly and just as well, vimlike editors will never be a replacement for a proper IDE. It’s fast, capable single file and small scope editor for me.


    I do also like all the alt and ctrl combinations with arrow keys to move lines, blocks and jump over words.

    • namingthingsiseasy@programming.dev
      link
      fedilink
      arrow-up
      1
      ·
      3 days ago

      I don’t even know where to start to make vim or neovim do all that. If it can’t do that seamlessly and just as well, vimlike editors will never be a replacement for a proper IDE. It’s fast, capable single file and small scope editor for me.

      If you’re interested in learning how to do it, I found this guide extremely helpful for getting started. it’s in both blog and video format, and it shows how to install Lazy (a package manager for vim), and which plugins to install to get LSP working (which is what would provide all the hotkeys that you were mentioning above).

      It’s definitely not a task for the faint of heart, but I found it very rewarding once I figured out how to work with the plugin systems because it’s so powerful and easy to customize. I found it helpful to just watch the video a few times to see everything working, then slowly started building up my own configuration (which was a bit more minimal than the linked guide I provided - I only installed about 30-40% of the plugins he listed on that page).

      Another alternative is Lazyvim, which provides an out-of-the-box configuration experience for you. It installs a lot of plugins and most things should work out of the box with very little configuration. It is a massive beast though, but still pretty good for a first start.

    • BartyDeCanter@lemmy.sdf.org
      link
      fedilink
      arrow-up
      0
      ·
      4 days ago

      Give Helix a try. It comes with everything you are asking for built in, plus discovery for the commands, plus a selection first approach so you can see what you’re doing.

  • rozodru@pie.andmc.ca
    link
    fedilink
    English
    arrow-up
    0
    ·
    5 days ago

    The thing about Vim is once you get the navigation down you’ll want it for everything and you’ll refuse to go back to anything else.

    I used Vim for so long that I can’t live without some form of vim style navigation. my Window Manager uses it, my web browser uses it, all my TUIs use it, hell I even switched to Emacs and installed Doom Emacs and THAT uses it. Now I only ever use a mouse for gaming because you realize that navigating around your PC purely with your keyboard is actually faster than using a mouse. I’ve disabled the touchpad completely on both my laptops.

    If you’re digging Vim check out NeoVim with LazyVim. makes plugins and theming and what have you easier. I use it as my backup to DOOM Emacs.

      • SlurpingPus@lemmy.world
        link
        fedilink
        arrow-up
        0
        ·
        4 days ago

        Try Vimium if you use Firefox, Chrome, or something Chromium-based. Invoking links with ‘f’ and a couple letters is so comfortable that I now get mad when the addon doesn’t work on Mozilla’s sites (due to security concerns) or when a site has ‘links’ implemented with JS.

        • loiakdsf@discuss.tchncs.de
          link
          fedilink
          arrow-up
          1
          ·
          1 hour ago

          thanks for the tip, i tried it and it feels amazing! it is just a bit janky with not working in new tabs, but i can work around that with the “old” browser based keyboard shortcuts.

      • rozodru@pie.andmc.ca
        link
        fedilink
        English
        arrow-up
        0
        ·
        5 days ago

        I use Qutebrowser. All links and interactions are keybound. so if for example I want to “click” on your user name I hit “F” which pops up a link hint and then hit whatever two letters are over the link. so for your profile it would be f + ll. that’s it. everything that it’s on a webpage that you would normally use a mouse to interact with can all be done with keybinds. It’s great, it’s quick.

        Browser navigation is also keybound. if I want to go back I hit shift+h. forward is shift+l. to switch tabs it’s shift+j or k. closing a tab is just pressing d.

        there’s also extenstions for chrome and firefox that will do the same thing like vimium and tridactyl.

        If you’ve used Vim for an extended period of time then navigating the same way in a browser is actually awesome. takes a bit to get used to but once you do you won’t go back and trying to use a browser with a mouse just feels slow.

  • marlowe221@lemmy.world
    link
    fedilink
    English
    arrow-up
    0
    ·
    5 days ago

    You probably already know this, but most IDEs have a setting to enable Vim keybinds or you can easily install an extension to add them.

    I really like Neovim but my job often requires some stuff that it doesn’t easily do. So, VSCode is what I use a lot of the time… with the Vim extension.

    Just something to consider if your stack isn’t super well supported in Vim/Neovim or you need tools it doesn’t have for your work.

    • msage@programming.dev
      link
      fedilink
      arrow-up
      0
      ·
      5 days ago

      I tried vim keybinds in an IDE, and it sucked.

      It wasn’t even that advanced usage, but it just didn’t work.

      Instead I know run language servers in neovim.

        • msage@programming.dev
          link
          fedilink
          arrow-up
          0
          ·
          5 days ago

          Keybindings are OK, but anything beyond movement was way less ok.

          Don’t remember if macros or buffers were implemented correctly.

          • witness_me@lemmy.ml
            link
            fedilink
            arrow-up
            1
            ·
            4 days ago

            Buffers do work in IntelliJ. Not sure about macros since I don’t use them. Haven’t checked VSCode. I found the IntelliJ plugin was better though.

  • CallMeAnAI@lemmy.world
    link
    fedilink
    arrow-up
    0
    arrow-down
    1
    ·
    5 days ago

    Vim is 40 year old garbage.

    If you need to edit files directly on a device go ahead bust it out, but you’re wasting your time decking that shit out with plugins for half the usability of an ide.

  • cosmicrose@lemmy.blahaj.zone
    link
    fedilink
    English
    arrow-up
    0
    ·
    5 days ago

    There are always more cool tricks and great plugins out there, have fun!

    Also I’d recommend Neovim, it’s exactly like vim except it supports Lua scripting, so there are lots of powerful plugins that aren’t available on vanilla vim.

    • galaxy_nova@lemmy.worldOP
      link
      fedilink
      arrow-up
      1
      ·
      5 days ago

      I’ll have to try neovim, and eMacs and all the derivatives. Honestly I just went straight to vim first because I wanted to try to OG experience first to see what it was like. I’ve also simultaneously been using vim mode in Zed which has been pretty nice too.

      • ma1w4re@lemmy.zip
        link
        fedilink
        arrow-up
        0
        ·
        5 days ago

        Can helix be fully controlled by keyboard? Does it have a 1-to-1 vim mode? Kind a interested in trying other editors, but I find vim controls are vastly more comfortable to anything that I tried so far

        • BartyDeCanter@lemmy.sdf.org
          link
          fedilink
          arrow-up
          1
          ·
          5 days ago
          1. Yes, Helix is a fully keyboard based editor. It does have some minor mouse support available but it is an afterthought.
          2. Nope! While the key map of Helix is fully configurable and by default similar to vi, it uses a select-verb grammar instead of a verb-select grammar.
            • Ŝan@piefed.zip
              link
              fedilink
              English
              arrow-up
              1
              arrow-down
              1
              ·
              5 days ago

              Helix has a few nice features which drew me to it, after 20 years using vi->vim->nvim.

              • Truly modal. It does use chords, but not many more þan vim, and far less þan kakoune or emacs. Most operations are modal, which is kinder to my RSI
              • Batteries included. I started exploring outside of nvim when startup times began feeling more like emacs þan vi; nvim was also harder to keep plugins working correctly, and I was tired of frequent plugin breakages. Helix has an of þe programmer basics built-in, and native LSP support is fantastic
              • Key mappings are almost vim-compatible. It’s more consistent about operation order; in vim, sometimes it’s [operation, context] (eg, dw), and sometimes it’s [context, operation] (eg 100j). In Helix, it’s always [context, operation], so its wd.
              • Helix has robust multiple disjoint selection support (as does kakoune). Once you get used to it, it is hard to do wiþout it.

              Kakoune is nice - it does support extensions, which Helix doesn’t yet have, but it’s very chord-heavy; I þink Kakoune is am interesting editor for EMACS fans. Helix follows vim’s modal model more closely