Neovim Power Tips: Volume 2

Поділитися
Вставка
  • Опубліковано 28 жов 2024

КОМЕНТАРІ • 49

  • @jotarokujo6099
    @jotarokujo6099 Рік тому +5

    I was constantly annoyed by #2. Didn't know there was a difference in p and P in visual mode. Very helpful!

  • @m47h4r
    @m47h4r Місяць тому

    These two videos were really useful. Well done.

  • @samcassidy2441
    @samcassidy2441 Рік тому +1

    Love the tip on combining macros with the g command! My solution would have been to include navigating to the next instance of background (using /) as part of the macro, but this is a nice alternative that's potentially more flexible

  • @robwells3713
    @robwells3713 Рік тому +1

    Very helpful video. `norm` was a revelation!

  • @phaberest_
    @phaberest_ Рік тому

    Good content! I'm still grasping quite a few

  • @mintcar
    @mintcar Рік тому

    I think your theming and colours look really nice.

  • @tandlose
    @tandlose Рік тому +3

    good video, would be nice with a thorough walkthrough of the command line in neovim. There are many videos explaining the basics of neovim with hjkl etc but few that explains the command line like norm etc

    • @benfrainuk
      @benfrainuk  Рік тому +1

      That’s a good idea. Will try and do a video on that soon. 👍

  • @PragandSens
    @PragandSens Рік тому +12

    thanks Hank from Breaking Bad

  • @visionary_3_d
    @visionary_3_d Рік тому

    Love your videos. Keep up the good work 🔥

  • @aaronmcadam
    @aaronmcadam Рік тому

    Thanks for this, really enjoyed it. And I think you're more of a Bruce Willis, personally 🤣

    • @benfrainuk
      @benfrainuk  Рік тому +1

      Ha. I’ll take that. Yippee Ki-yay …

    • @sp3ctum
      @sp3ctum 8 місяців тому

      @@benfrainuk a great username would be "Bruce Vimis". Okay, maybe not that great. 😄

  • @WillEhrendreich
    @WillEhrendreich Рік тому

    Awesome stuff thanks!

  • @gennarotedesco7973
    @gennarotedesco7973 Рік тому

    Hi Ben, great video! If I understand correctly, you are using delta as vimdiff within the gitsign plugin? Could you expand on how you configured it (I am using delta as well but as far as I know there is no way to use it as drop-in replacement for the in-built vimdiff, but I hope I am wrong :) )?

    • @benfrainuk
      @benfrainuk  Рік тому

      The command I typically run is ‘:Gitsigns diffthis ~1’ that gives me a diff with solid background colours. There is supposed to be a way of getting it setup with Telescope too but it looked too convoluted for me to bother!
      Actually, now I look at my config, I’m not even sure Gitsigns is actually using delta! I think I only actually have delta working inside Lazygit. The fact that git signs shows me solid colours as opposed to the +/- that Telescope uses made me think it was using git-delta but now I am not sure!

    • @gennarotedesco7973
      @gennarotedesco7973 Рік тому

      yes, however gitsigns uses the inbuilt vimdiff to show the differences, it does not take as option an external diff program (like delta), does it?

  • @craigdanielmaceacher
    @craigdanielmaceacher Рік тому +1

    using vim-unimpaired makes pasting above and below easier with [p and ]p plus it has other variants to indent as well as paste so you can do >]p

    • @benfrainuk
      @benfrainuk  Рік тому

      I’ve actually taken to using mini-bracketed for this thanks to your suggestion. It’s a nice way to think about the above and below, thanks 🙏

  • @whirr9755
    @whirr9755 Рік тому +1

    how do you get that colorful animation on the line number when jumping at around ~ 2:40 ? thanks

    • @benfrainuk
      @benfrainuk  Рік тому

      github.com/gen740/SmoothCursor.nvim 👍

  • @gplusplus314
    @gplusplus314 Рік тому

    Thanks for another great video! Hey just FYI, your audio has a lot of unintended bass. It’s making my subwoofers shake the house, usually whenever you type. Think “Jurassic Park” when the cup of water is rippling each time the T-Rex 🦖 takes a step.
    Solution: do a low-cut (or high pass) at 120 hz or higher. Pretty much any video or audio editing tool can do this. 😉

    • @benfrainuk
      @benfrainuk  Рік тому +1

      Thanks, I’ll take a look for the next one. I was told by someone into audio that at the end of my edit to slap a compressor filter onto the audio. That definitely boosts everything but maybe at the expense of being too much! Will try the next one without that.

    • @gplusplus314
      @gplusplus314 Рік тому

      @@benfrainuk The compression sounds good! You just need to do a low-cut *after* the compressor. So basically just chop out anything below 120 hz or so. Play with that number until you’re happy with the result, basically. Some compressors have a built-in way of doing this, but the mental model should be “compress first, then cut out the bad frequencies after.”
      “Shake the house” bass starts at about 80 hz, to give you an idea. “Shake the entire Earth” happens at 30 hz or so, which is a hell of a surprise when waking up with my morning coffee. Haha!
      🦖 ☕️

    • @benfrainuk
      @benfrainuk  Рік тому +1

      @@gplusplus314 ok great 🤣 sorry about that, I’ll give the low cut a go next time 👍

    • @benfrainuk
      @benfrainuk  Рік тому +1

      Tried your suggestion on the audio for my latest review (Glove 80). If you get chance to take a look/listen, let me know if that’s an improvement. Thanks again. 👍

    • @gplusplus314
      @gplusplus314 Рік тому

      @@benfrainuk Yes sir! Sounds great! I’ll miss the house rattles, but the quality content is a worthwhile tradeoff. 🤣

  • @pwnwriter
    @pwnwriter Рік тому +1

    map j -> jzz
    k -> kzz

  • @dbsmith3974
    @dbsmith3974 Рік тому

    I was looking for the function that you added to telescope... is it in your blog?

    • @benfrainuk
      @benfrainuk  Рік тому +1

      Sorry! Just added the links to the description 👍

  • @pilkers745
    @pilkers745 Рік тому

    hey ben! do you use tmux as well by chance??

    • @benfrainuk
      @benfrainuk  Рік тому +1

      I don’t. I find Kitty is enough for my needs.

  • @sudqi
    @sudqi Рік тому

    For deleting everything after commad instead of "df," you can do "dt," it will delete till the comma

    • @benfrainuk
      @benfrainuk  Рік тому

      But I want to delete everything AFTER the comma, not before. So I don’t think ‘dt,’ would help would it? Have I misunderstood?
      Another option that would do it though would be to work from the other end, so ‘norm $dF,x’ so we go to the end of the line, then delete back to the comma, then x to remove the character under the cursor

    • @sudqi
      @sudqi Рік тому

      ​@@benfrainuk I've misunderstood you sorry.
      I honestly use the substitute way more frequent .

    • @sibouras792
      @sibouras792 Рік тому

      this is late but you could just move the cursor with l, so `dt,l`

  • @brandondapro
    @brandondapro Рік тому

    Have you switched from sublime to nvim?

  • @mzerone-g6m
    @mzerone-g6m Рік тому

    Emacs where emacs

  • @imaksimus
    @imaksimus Рік тому +1

    Thanks for the video, it’s great.
    To copy unequal string you could also do :%!awk '{print $3}'

    • @benfrainuk
      @benfrainuk  Рік тому +1

      Cool! Will have a look at that and try and understand. Have had a tab open ‘Understanding Awk’ for about 4 years I still haven’t read 🤣

    • @imaksimus
      @imaksimus Рік тому

      @@benfrainuk this is similar to the ripgrep example you show later in the video. Essentially it is a filter which prints the third column of each row.

    • @benfrainuk
      @benfrainuk  Рік тому

      @@imaksimus oooh, that’s really cool. Thanks, I am reading that article right now 👍👍

    • @imaksimus
      @imaksimus Рік тому

      @@benfrainuk one more thing from me and I’ll shut up 😅
      To delete everything after a comma, the following replace command would work too:
      :%s/,\zs.*/

    • @benfrainuk
      @benfrainuk  Рік тому

      @@imaksimus I’ll happily take everything you’ve got 👍