VIM The Ultimate Editor

แชร์
ฝัง
  • เผยแพร่เมื่อ 21 พ.ย. 2024

ความคิดเห็น • 268

  • @chrissaltmarsh6777
    @chrissaltmarsh6777 2 ปีที่แล้ว +103

    I'm 72, used Bill Joy's vi in the late 80's
    The muscle memory is still with with me (I use neovim now)
    It was, and is, brilliant if you want to write code while concentrating on thinking about the code you are writing or editing.
    You learn how to transfer thoughts to a keyboard without really thinking about how.
    That is what is so clever about the original vi. Designed to do what you need.

  • @cdey3886
    @cdey3886 2 ปีที่แล้ว +28

    I switched from vscode to Vim a few months ago and I can not stress enought how much I love it. And imo, it's not just for programers if you write blogs it's a must have!

  • @VictorRodriguez-zp2do
    @VictorRodriguez-zp2do 2 ปีที่แล้ว +33

    20:44 - An alternative to this that a lot of people use is remapping your Caps lock key to escape, an even better alternative is remapping your caps lock key to escape AND control, so that when you press caps lock alone it's registered as escape and when you press it with another key it counts as CTRL. In Linux there's this package called caps2esc which does that (it does it for every program not just VIM). When I discovered this I felt like a kid in a toy shop

    • @foss_sound
      @foss_sound 2 ปีที่แล้ว +2

      That indeed could be a gamechanger. Ty for sharing.

    • @nodidog
      @nodidog 2 ปีที่แล้ว

      I've been using this setup for a year or so, it works well 👍

    • @sspaeti
      @sspaeti 2 ปีที่แล้ว +1

      I do similar things, but instead of ESC and Ctrl, I use ESC and Caps and map e.g. HJKL with Caps for moving the arrow key generally. Now I can use arrow keys with homerow in any app outside of vim as well. Caps A for umlaut etc. So I have another layer of shortcuts.

  • @yvrelna
    @yvrelna 2 ปีที่แล้ว +66

    Coming from a Vim veteran here, there's nothing wrong with mouse=a
    Keyboard moves are great for quick and precise movements, but there are times when using the mouse just makes a lot of sense, like when you're browsing texts without specific aim and doesn't actually need to edit anything. Don't feel like you have to use the keyboard all the time, the mouse is there to be used.
    The problem is if you're using the mouse as a crutch instead of actually learning vim keyboard keys. That'll make it hard to actually improve your editing efficiency.

    • @zeocamo
      @zeocamo 2 ปีที่แล้ว +1

      that is why neovim got it out of the box and got right click menus too.

    • @danmar007
      @danmar007 2 ปีที่แล้ว

      I often challenge myself at using only my mouse to navigate Windows. In fact, one of the things I used to show new Windows users was how much you can do with just the mouse.

    • @entelin
      @entelin 2 ปีที่แล้ว +3

      @@zeocamo When I just read your comment I was like "wtf is he talking about? right click?" then I right clicked on my neovim window.. "omg he's right XD"

    • @entelin
      @entelin 2 ปีที่แล้ว +5

      I agree. If you are actively editing in vim, then your hands really should be both on the keyboard. However if I'm going back and fourth between a web browser, or an image editor or whatever, then my right hand wont be on the keyboard. So that creates some tension, and there's cases for example where I will highlight and scroll with the mouse in vim because my right hand is already there and will probably need to stay on the mouse in the next moment when I go back to whatever else I was doing.

    • @user-he4ef9br7z
      @user-he4ef9br7z 2 ปีที่แล้ว +4

      Heresy. Your computer shouldn't even have a mouse.

  • @drescherjm
    @drescherjm 2 ปีที่แล้ว +39

    I used to be descent at vim in the 1990s when remotely programming on unix at the university however I have unfortunately forgotten everything about it and stick to nano from a terminal for at least the last 15 or so years.

    • @DarkGladiator
      @DarkGladiator 2 ปีที่แล้ว +1

      Why did you forget it? is it because you stopped using computers for a while or just stopped using vim

    • @drescherjm
      @drescherjm 2 ปีที่แล้ว +7

      @@DarkGladiator I had moved on to a windows software development and network admin job after I graduated and did not use vim. However a few years into that 2002/2003 I switched to using gentoo linux servers but the default editor was nano.

    • @FakhryHTatanaki
      @FakhryHTatanaki 2 ปีที่แล้ว

      Eyy I can relate to my uni days as well, the labs had windows installed 😝, so I ssh to my home server to do the programming using VIM

    • @drescherjm
      @drescherjm 2 ปีที่แล้ว +1

      @@FakhryHTatanaki When I started in 1989 the labs had vt100 terminals but those were eventually replaced by solaris workstations and windows machines. I was a student at the university for 6.5 years and I work for them for 25+ now.

    • @jarnobot
      @jarnobot 2 ปีที่แล้ว

      You might want to give Micro a try.

  • @rkdeshdeepak4131
    @rkdeshdeepak4131 2 ปีที่แล้ว +6

    The Primeagen can convince someone who doesn't even have a computer just by his excitement

  • @sandmanxo
    @sandmanxo 2 ปีที่แล้ว +2

    I was a vi user since the 90s and switched to vim 3 years ago when a coworker was using it. It's the first thing I install on any distro, or even inside dockers containers.

  • @sysandy2
    @sysandy2 2 ปีที่แล้ว +9

    I've been a vi(m) user for the past 20+ years. I started my sysadmin career working on Solaris 2.6 and BSDi systems which were pretty primitive compared to today. I will say that even though I have been a long time user I still learn a new trick now and then. You will be surprised by how quickly those key strokes become muscle memory. Also, I always set vi keybindings (set -o vi) in my shell; try it if you have not already done so.

    • @vikingthedude
      @vikingthedude 4 หลายเดือนก่อน

      I did NOT know we could do that in our shell. Ill check it out first thing tomorrow

  • @KeepEvery1Guessing
    @KeepEvery1Guessing 2 ปีที่แล้ว +7

    Do be sure that you can use it without your customized settings. A great advantage to vim is that it's always there on a Linux box. In fact, there is some advantage to knowing how to get by in vi, because the *nix systems that aren't Llinux may not have vim, but will have vi, and the basics are the same. (I prefer emacs myself, but that's rarely pre-installed on other peoples boxed. I started out with TECO - old old guy - which was what Stallman originally wrote emace in, since it was a highly programmable editor even way back then.)
    BTW, the direction for the arrow keys is that the DEC VT-52 and others had arrows over the letters on HJKL keys. I believe that HACK, a game from those days uses the same direction keys, or did.
    And vi, and maybe vim, has exed mode (:ex), harkening back to when we edited on printing terminals like teletype machines (I did my thesis on an Execuport 300 in the TJ6 markup language). Probably not worth it for you, but it's good to know if you wind up having to edit over a VERY slow connection, where having your screen constantly updated is just untenable.

    • @tanmaypanadi1414
      @tanmaypanadi1414 2 ปีที่แล้ว

      Cool ,Thank you for sharing

    • @Winnetou17
      @Winnetou17 2 ปีที่แล้ว +2

      Hack and NetHack do use the HJKL. Also, NetHack is still being developed to this day (though it's mostly bugfixes for those insanely obscure cases + QoL improvements)

  • @avocado9227
    @avocado9227 2 ปีที่แล้ว +4

    Vim is like the alphabets for any language; the sooner you learn it, the sooner you benefit from knowing it. Similarly, the sooner you learn how to touch type, the sooner you benefit from the productivity that comes with knowing where ASDF is on the keyboard. Only you and you alone will benefit from Vim's high productivity until death do you part.

  • @mithubopensourcelab482
    @mithubopensourcelab482 2 ปีที่แล้ว +1

    This will be my 149th attempt to learn Vim after watching your video. Thanks Chris.

  • @RobotechII
    @RobotechII 2 ปีที่แล้ว

    I switched to Vim back in 2015 and it's been amazing. I need to go through my plugins and remove the old junk and look for new plugins. To learn Vim you need to immerse yourself completely and not lean on any crutches and you'll be competent within a week.

  • @PinakiGupta82Appu
    @PinakiGupta82Appu 2 ปีที่แล้ว

    Press 'Ctrl+[' in insert mode instead of pressing Escape and change the mode to normal mode. 'Control' plus 'Third Bracket'. Or, simply map ''jk"/"jj" to Escape. Using the mouse seems fair sometimes when you have to copy from other application windows such as a web browser. There's no shame in admitting that after using Vim loosely since 2013, I don't think that I'll know everything about Vim even at the end of my life. Nobody is a Vim master. It's just a matter of the level of mastery. How one uses Vim also counts. I still learn from new Vim users. I still look at vimrc files dated back to 1997. Like learning in all other disciplines, the journey to acquire mastery in Vim is a never-ending process.
    Good job! Keep it up!

  • @michaelkrailo5725
    @michaelkrailo5725 8 หลายเดือนก่อน

    To overcome that confusion between j for down and k for up, just make a gesture pointing down and say to your self "Your going down!". It's very natural to point down with your forefinger. Of course, pointing up with just your middle finger conjures the "Up yours" phrase. Those two mental images should get you going in the right direction more often.

  • @jefferygrantham5582
    @jefferygrantham5582 2 ปีที่แล้ว +8

    Instant like for quickly addressing the "how to exit vim" argument. ZZ and ZQ for the win! String replacements in vim are magical also. Syntax is just like using sed. Undotree is one of my absolute favorite plugins for vim using vundle.

    • @DarkGladiator
      @DarkGladiator 2 ปีที่แล้ว

      No no you must reboot!!!

    • @edge3646
      @edge3646 2 ปีที่แล้ว

      nice

    • @zeocamo
      @zeocamo 2 ปีที่แล้ว

      yes .. newbie found ZZ and ZQ is for the people who just started out, but Chris is getting there, and we just need to keep helping him in he's steams.

    • @zeocamo
      @zeocamo 2 ปีที่แล้ว

      gundo is also nice

  • @danmarvarela1446
    @danmarvarela1446 2 ปีที่แล้ว +3

    One of the many things I learned using vim is one could map H and L to :bprev and :bnext respectively in nomal mode to move left and right between open buffers just for the muscle memory (since h and l navigates left and right respectively). H is for moving the cursor on top of the screen but one could use gg for that. L is for moving the cursor to the bottom of the buffer but one could use G instead.

    • @michaelkrailo5725
      @michaelkrailo5725 8 หลายเดือนก่อน

      I like that remapping idea for H and L to switch buffers, but your wrong about what the original H and L commands do. They only go to the top or bottom of the viewable buffer, not the entire file. I normally just use leader(space) p or n to go to previous or next buffer.

  • @mateiberatco500
    @mateiberatco500 2 ปีที่แล้ว +2

    "The first thing to learn"...to exit: I remember an article comparing Windows (XP or 98) to Linux where the reviewer gave point to Windows because he couldn't shutdown Linux. It worked for a whole week (Linux stability), but he wanted to turn off his PC during the night.

  • @gwgux
    @gwgux 2 ปีที่แล้ว +2

    He finally did a video dedicated to Vim! Good coverage on it! Vim is a beast where there's always more to learn for how to use it in new ways, especially with the plugins. At least you don't need to be an expert to be proficient and able to benefit from it. Learn the basics and you'll already start being more efficient in how you edit files.

  • @Gryfang451
    @Gryfang451 2 ปีที่แล้ว

    I came here to learn more about VIM, but I'm over 50, what should I do?
    If you're in IT, you should learn something new every day. It will keep you from stagnating. Once that sets in, you're pretty much done for. The great news for those of us over 50 is that eventually you will forget what you learned yesterday, so tomorrow will seem all fresh again and you get to re-learn it all over! Just like all those cert questions you learned and dumped within minutes of passing your MCSA or Security+. I can't remember what I had for dinner a few hours ago, but I can still remember an activation code for Windows XP. Thanks for the video Chris! When you pass 50, hit me up and we'll put arthritic fingers to keyboards and see who can still write PowerShell without using Google. I figure by then, PowerShell will be like the Windows XP license and I'll be able to just start typing...

  • @zinsy23
    @zinsy23 2 ปีที่แล้ว

    I agree with your view on j and k! When I first learned VIM, I decided to configure the vimrc to flip them around using nmap so I didn't have to bother making myself miserable learning the default way. So much better!

  • @zeocamo
    @zeocamo 2 ปีที่แล้ว +9

    the g in the substituting is for global, and if you first select the lines with visual mode, then it will only run on the selected lines, then you can do(without %) :s/"//g and without the g here it will only replace the first " on the line

    • @FabianBarajas
      @FabianBarajas 2 ปีที่แล้ว +4

      Just to add on something I find useful, the '%' sign at the beginning of the command tells the substitute command to run over the current file/buffer. You can also set a range using line numbers :20,30s/findthis/replacewiththis/g. The 'g' tells the substitute command to replace all occurrences of the located search expression on a line that it's operating on, otherwise it will only change the first occurrence on each line it operates on.

  • @MrHappygolfer
    @MrHappygolfer 2 ปีที่แล้ว

    Accidentally found vi in 1996, while investigating a Solaris 2.3 machine. Was hooked on Vim while learning Linux in 1997.

  • @shutdowncnn6086
    @shutdowncnn6086 2 ปีที่แล้ว

    ThePrimeagen, the speed demon of Vim. Can't believe you have not discovered him until now? I have been watching this guy for a while. I use Vim for my Linux note taking. My Linux notes are 14,000 lines long. Vim let's me move effortlessly to my documented command lines and scripts quickly.

  • @kev2020-z9s
    @kev2020-z9s 2 ปีที่แล้ว

    Thank you have learnt so much from you and JustAGuy Linux , DistroTube over the last two months. As a long time windows user (98 to win10? To big and loaded with stuff that I never used) I was so used to changing something in windows and waiting for the blue screen of death that I just stopped changing things. You have give me the confidence to try things in Linux and make the system suit me thank you again keep up the good work.

  • @Mikesco3
    @Mikesco3 2 ปีที่แล้ว +2

    It's really fun to watch your journey.
    Also nice to compare it to our own journey.

  • @MrKristian252
    @MrKristian252 2 ปีที่แล้ว +2

    15:08 Oooo! For this I would use the multi cursor plugin. Select the content you want to search, then CTRL + N to duplicate the cursor till you've selected all of them, and then now you have selected all of them.
    I don't think I can link the github page, because I'm getting the feeling youtube is hiding comments containing links

  • @zeocamo
    @zeocamo 2 ปีที่แล้ว +3

    4:30 no it is not the only 3 modes, you can do a :h vim-modes for the full list and more details but it is notmal, visual, select, insert, command-line, ex, terminal, operator-pending, replace, virtual replace, insert normal, insert visual and insert select mode.
    so that is 13 modes not 3 but 13

  • @VictorRodriguez-zp2do
    @VictorRodriguez-zp2do 2 ปีที่แล้ว +2

    Don't worry about hkjl, I also had trouble with it but after a while you get used to it. It's the same with a lot of VIM features they seem pretty counter-intuitive at first but after some time you feel like you are flying

    • @xn1kkix
      @xn1kkix 2 ปีที่แล้ว +2

      10:06 Chris vocalized the mechanical crisscrossed confusion as it was experienced

  • @WayneSmith619
    @WayneSmith619 2 ปีที่แล้ว +1

    Nice thing about vim is when somebody else tries to use your terminal they just sit there an press the escape key to leave, which is harmless and amusing. It is like having an editor with a keyboard lock.

  • @seyu8666
    @seyu8666 2 ปีที่แล้ว

    I absolutely love vim! Been using it for more than two years now

  • @369time7
    @369time7 2 ปีที่แล้ว

    OMG you triggered VIM PTSD from college. I thought I had forgotten it. Vim on orange VAX terminals in Cobol class. Lucky us it was the very last semester it was required. We were busy reveling in Win-95 and dissing ancient systems.

  • @zeocamo
    @zeocamo 2 ปีที่แล้ว +9

    if you start with neovim in stand of vim, it is more new user friendly with mouse support out of the box, and better default settings making it easier to get start.

    • @ChrisTitusTech
      @ChrisTitusTech  2 ปีที่แล้ว +6

      Agreed, I just moved since the video was made.

    • @StillConfusing
      @StillConfusing 2 ปีที่แล้ว +2

      neovim is also great because lua is a real language that's pretty useful to know, and is also super fast

    • @zeocamo
      @zeocamo 2 ปีที่แล้ว +3

      @@StillConfusing yes and it easy to write in, and the LSP and treesitter and telescope and nullls etc. it is at a place now that you can build a great editor for you, or a PDE as Teej_dv call it.

    • @Kalasklister1337
      @Kalasklister1337 2 ปีที่แล้ว +1

      If you for some reason do not like to figure out all your plugins on your own and your are switching from something like vscode, your should definitely try lunarvim initially created by a person also named Chris (chris@machine). It is a pretty popular set of neovim configs that makes neovim behave more like a modern IDE without you having to configure much. I'm sure there are other projects like it and you can try those as well.

    • @zeocamo
      @zeocamo 2 ปีที่แล้ว +1

      @@Kalasklister1337 yes lunarvim is a nice project that i also help with a few things, but when you use it for a while then you need to learn get to fix stuff in neovim maybe with your own config

  • @Vashinator7
    @Vashinator7 2 ปีที่แล้ว +4

    Nice. Kinda thinking my first live stream will be speed running vim tutor in neovim haha.
    Plan to dive into neovim quite a bit and work on some lua and python I believe

  • @jamesyoung151
    @jamesyoung151 2 ปีที่แล้ว +1

    I've been using vi the very first time I touched a unix system. When I install linux, vi/vim is one of the first things I install. I never learned any other editor. I have a cheat sheet from when I was in college.

  • @HectorGonzalez-vp1ss
    @HectorGonzalez-vp1ss 2 ปีที่แล้ว +1

    I too was amazed the first time I saw some theprimeagen videos, looks like chris just going through the same.

  • @cyphodias1640
    @cyphodias1640 2 ปีที่แล้ว +1

    Undo Tree feels like a local GitHub repository showing all your undo commits.

  • @davidtipton514
    @davidtipton514 2 ปีที่แล้ว

    I used vi in unix for many years! Thanks for the video...

  • @yvrelna
    @yvrelna 2 ปีที่แล้ว +3

    6:18 "that's five words back... or actually there's some dots there, so it'll be three b from here, or two b, I can't count..."
    😂, but seriously, use the capital W/E/B instead if you want to ignore all those special characters, it's generally easier to count that way.

  • @TuxWing
    @TuxWing 2 ปีที่แล้ว +1

    Vi(m) is definitely the best command line editor. But I appreciate IDEs that have vi(m) capabilities either natively or via a plugin...and as long they exist, I use them every time.
    Oh BTW, the /etc/fstab can use double quotes just fine as I use them without issue.

  • @blevenzon
    @blevenzon 2 ปีที่แล้ว

    Yessssssss!!!! I was waiting for this Chris. Woooohooo

  • @Kenny.Orellana
    @Kenny.Orellana 2 ปีที่แล้ว +1

    You could remap Esc to jj or jk by adding
    imap your_key_combination
    To your vimrc file and does the same thing you say the plugin does

  • @corvusabaddon
    @corvusabaddon ปีที่แล้ว

    I love that Mandalorian poster.

  • @Rez996
    @Rez996 2 ปีที่แล้ว +1

    Personally, I just use "ctrl + [ " to escape out of insert mode. Saves on reaching for the escape key and also saves on having to use a plugin and/or script.
    Another option is using a macro tool to rebind "right-Alt" to "ESC".

    • @rkdeshdeepak4131
      @rkdeshdeepak4131 2 ปีที่แล้ว +1

      Map jk and kj to ESC, best thing. Will cause initial delay while navigatingbup or down though

    • @nodidog
      @nodidog 2 ปีที่แล้ว +1

      Re-map caps-lock to be Esc when tapped, and Ctrl when held. I would never go back, it's so easy to use.

    • @JedHurricane
      @JedHurricane 2 ปีที่แล้ว

      @@nodidog Say what? Also, how do you set up hold to ctrl?

    • @nodidog
      @nodidog 2 ปีที่แล้ว +1

      @@JedHurricane Caps lock is ESC when tapped, and control when held (or pressed in combination with another key).
      I use a bit of software called karabiner elements.

    • @GiovanniCKC
      @GiovanniCKC ปีที่แล้ว

      @@rkdeshdeepak4131 you can use `:set ttimeoutlen=100` to speed that up a bit (it's because it's checking to see if you'll hit both keys in the mapping before it interprets it as the normal single key)

  • @MoGuy-zy1gh
    @MoGuy-zy1gh 2 ปีที่แล้ว +4

    Hey Chris. In one of your past videos, ("Installing Linux The "Right" Way") you mentioned that you had created your own personal Debian mirror, and that you would soon make a video on how you did that. Did you ever make that video? I've been wanting to create a personal mirror of my own, and would like some direction. Thanks!

  • @xn1kkix
    @xn1kkix 2 ปีที่แล้ว +1

    Ara ara, Chris just invented a letter. 10:06

  • @gradientO
    @gradientO 2 ปีที่แล้ว +4

    I recently felt the need to learn vim because using arrow keys often isn't that efficient

  • @AndrewErwin73
    @AndrewErwin73 2 ปีที่แล้ว +3

    I suggest lunar vim if you want to use neovim as an IDE. It has everything you need, including LSP, Git integration, fuzzy finders, menu system... it is my favorite.

    • @jupiteriana
      @jupiteriana 2 ปีที่แล้ว +1

      I'm having a hard time understanding what Lunar Vim is, is it Neovim with preinstalled plugins?

    • @AndrewErwin73
      @AndrewErwin73 2 ปีที่แล้ว +1

      @@jupiteriana it is a ton of plugins! But the coolest thing is microsoft's lsp (language server protocol) which provides stuff like intellesense, syntax highlighting, etc. for almost any language you can think of. Also Git integration (do all of your git management from inside neovim)... essentially, it turns neovim into a full fledged IDE!
      You can get all of this stuff (or less) without lunar vim, but it is nice to have it all in once place.
      There are other packages that do similar things... lunarvim is the one I landed on.

    • @jupiteriana
      @jupiteriana 2 ปีที่แล้ว

      @@AndrewErwin73 thank you!

  • @toromac9786
    @toromac9786 2 ปีที่แล้ว

    used to hate vim as well, until I decided to remove nano and force myself to use vim. I'm not proficient by any stretch of the imagination, but turning on vim mode in Obsidian really helped!

  • @bastianp982
    @bastianp982 2 ปีที่แล้ว +3

    Best random password generator: give a non-tech person a vim and ask them to exit

  • @DJ_Cthulhu
    @DJ_Cthulhu 2 ปีที่แล้ว +3

    One word; EMACS 😈

    • @zeocamo
      @zeocamo 2 ปีที่แล้ว +1

      yea, Emacs is not useful any more after neovim got lua, now it is neovim that not all the plugins, email client too ;)

    • @entelin
      @entelin 2 ปีที่แล้ว

      @@zeocamo This. There's still some benefits that emacs has, like client/server. But the advantages emacs has had are quickly evaporating.

  • @michaelplaczek9385
    @michaelplaczek9385 2 ปีที่แล้ว +1

    Vim has buffers, that’s cool

  • @_Code.Pilot_
    @_Code.Pilot_ 2 ปีที่แล้ว +2

    I had the same issue with "j" and "k". I started thinking about the bottom curve of "j" as pointing downward.

  • @SigmaTapion
    @SigmaTapion 2 ปีที่แล้ว +2

    Though you need some extra fonts installed, I've found AstroNvim to be a pretty good intro into using vim as an IDE
    Probably not optimal as regular vim/nvim with the same type of plugins and your own config is probably better, but.... it's a good fit for me

  • @nodidog
    @nodidog 2 ปีที่แล้ว

    I highly recommend the book 'Practical Vim' by Drew Neil if you want to up your game. It's a treasure trove

  • @peterjansen4826
    @peterjansen4826 2 ปีที่แล้ว +1

    Yeah, now Chris says that. It took some effort to get him there. 😁But he is right, it is the perfect editor.

  • @generalfun6960
    @generalfun6960 2 ปีที่แล้ว +2

    Do you know the vimium plug in for the browser ? You can use the vim stuff on the browser works on chromium and firefox.

  • @ucielsola
    @ucielsola 2 ปีที่แล้ว +1

    BLAZINGLY FAST!

  • @AndrewErwin73
    @AndrewErwin73 2 ปีที่แล้ว +2

    Prime also uses a DVORAK keyboard! I assume he has remapped keys so navigation is similar.

  • @b1zzler
    @b1zzler 2 ปีที่แล้ว

    I prefer VS Code. Not because I like the UI or use any of its features and extensions but because it's an Electron application powered by JavaScript, the most-loved programming language among software engineers.

    • @astratow
      @astratow ปีที่แล้ว

      I think Richard Stallman would disagree with this statement. I am also not the biggest fun of js.

  • @foss_sound
    @foss_sound 2 ปีที่แล้ว

    Didn't know there is a way to share the yanks to the system via vimrc. Yay!

  • @wishmaster1449
    @wishmaster1449 2 ปีที่แล้ว +2

    Thanks for sharing your vim's configuration, Chris. I have a question. How do you open the Markdown previews? Do you have another plugin or you can do it with vim-markdown?

  • @Dusta_Rhymes
    @Dusta_Rhymes 2 ปีที่แล้ว

    What a lot of noobs (no offense) don't get is that even just the tippy tip of the vim iceberg will speed up your workflow. Just using the movement keys, search, and especially find and replace is way faster than not using vim.

  • @eduardoarandah9990
    @eduardoarandah9990 2 ปีที่แล้ว +2

    Let me suggest mastering splits and tabs. It was a game changer for me to explore code

  • @AnzanHoshinRoshi
    @AnzanHoshinRoshi 2 ปีที่แล้ว

    Thank you, Chris.

  • @billbinder7754
    @billbinder7754 ปีที่แล้ว

    When MSDOS appeared, I used to prefer EDLIN to vi and any of it's rat-infested descendants. Because for several years In the 80's. I had to write software with vi and document it with vi & nroff. On terminals where all sorts of keys (up/down/let/right/etc) generated ESC sequences, happily terminating whichever idiotic vi mode you were in and dropping you into something random. EDT on VAX/VMS was marginally more useful, EDIT on MSDOS was not bad, TPU (also VAX) was rather lovely, and MicroEMACs was bliss. I do still remember how to get out of vi(m) and how to do the very basic stuff, lets call it scar tissue. It's surprisingly visceral after all those years. Sorry, nuffin personal.

  • @AndrewErwin73
    @AndrewErwin73 2 ปีที่แล้ว +1

    Aside from tabs, you can also split the screen horizontally or vertically.

    • @entelin
      @entelin 2 ปีที่แล้ว +1

      You can and I certainly use that. Though I think if you are making extensive use of splits and tabs there may be an issue with your workflow that could be improved with various kinds of jumps and finders.

    • @AndrewErwin73
      @AndrewErwin73 2 ปีที่แล้ว

      @@entelin I don't disagree with that completely! In general I use tmux anyway. But there are times when I want to compare files or something like that. But yeah, you are right. Tabs, buffers, and a fuzzy finder SHOULD be plenty for a normal work flow.

    • @entelin
      @entelin 2 ปีที่แล้ว +1

      @@AndrewErwin73 ctrl i, ctrl o, and if coding lsp based jumps like jump definition and so on. I wish neovim would add a client/server solution where you could attach multiple copies of the client to a single server holding all the buffers. Because without that you can't be editing the same files across multiple tmux, or multiple systems, or split between monitors, etc. For example I have about 150 source files in my current programming project. Often I just open them all in the editor at once with vim src/*, but even if I didn't as I navigate I accumulate buffers and if then another copy of vim is opened it will step on that. There are multiple neovim gui clients, one of which supports detaching vim windows "fvim" so that's another possible solution though I haven't tried it yet.

    • @AndrewErwin73
      @AndrewErwin73 2 ปีที่แล้ว

      @@entelin nice! I haven't pushed neovim to that limit just yet! But it is good to know that I could.

  • @str33tkng
    @str33tkng 2 ปีที่แล้ว +3

    EMACS for me, but vim is great too.

    • @astratow
      @astratow ปีที่แล้ว

      I am still to get there. Emacs is vast.

  • @neil_from_future
    @neil_from_future 2 ปีที่แล้ว

    10:17 I totally agree with you about j and k, I always thought j(up) and k(down) that how my brain work but vim is not. Anyway what your distro you use and why is looking so colorful, I've never see any distro have topbar like that.

  • @paulstokes1992
    @paulstokes1992 2 ปีที่แล้ว

    Thanks... it's working... Good Job...!

  • @danmar007
    @danmar007 2 ปีที่แล้ว +1

    I had to find out once and for all. There is a Vigor editor. Next video: become an expert at Vim and vigor.

  • @matthiasbenaets
    @matthiasbenaets 2 ปีที่แล้ว +3

    Emacs The Ultimate Editor

  • @SimGunther
    @SimGunther 2 ปีที่แล้ว +3

    What about Neovim? Love it so much that I mapped the vim alias to nvim on my bashrc.

    • @ChrisTitusTech
      @ChrisTitusTech  2 ปีที่แล้ว +4

      Just moved from vim to nvim 2 days ago after I finished this video lol.

    • @zeocamo
      @zeocamo 2 ปีที่แล้ว

      @@ChrisTitusTech you only on the top of a really deep hole right now, if you push on with this in 30-60 days, you will be so close to Prim .. it go really fast when you start looking on others dot files and find lua plugins.

    • @John-Dennehy
      @John-Dennehy 2 ปีที่แล้ว

      @@ChrisTitusTech Was going to ask the same question, but while checking your github for the cool terminal formating I happened to see the recent neovim repo :D Can't wait to see that video ;)

  • @r.b.587
    @r.b.587 2 ปีที่แล้ว +1

    I use vim (or gvim) just because I'm used to it. Sometimes I use vscode depending upon my mood. Going to another editor seems like a major time investment which I'd rather not do. Enjoy the videos.

    • @donaldmickunas8552
      @donaldmickunas8552 2 ปีที่แล้ว

      I can’t use another editor easily. I keep trying to use the vim keys out of habit.

    • @user-he4ef9br7z
      @user-he4ef9br7z 2 ปีที่แล้ว

      I can't use anything that doesn't have vim keybindings.
      My email, pdf viewer, browser, file manager everything has vim keybindings at this point.

    • @user-he4ef9br7z
      @user-he4ef9br7z 2 ปีที่แล้ว

      @ISCARI0T Neomutt

  • @ambuj.k
    @ambuj.k 2 ปีที่แล้ว +2

    The very first thing I do when I install vim is to remap j+k to esc in insert mode so I never have to move my hands off of the home row; ctrl+[ is also a great default alternative to pressing escape in vim, escape is just a major annoyance when you quickly switch between normal and insert mode very often.

    • @Joe_Brig
      @Joe_Brig 2 ปีที่แล้ว +1

      I hate the default location of escape and control, so at the OS level I mapped caps-lock to escape if pressed alone. I also have caps lock mapped to control when pressed with another key.

    • @ambuj.k
      @ambuj.k 2 ปีที่แล้ว

      @@Joe_Brig That is some complex keymapping, idk how you'd do that. I use windows and wsl so I just set jk to escape in vim extension settings.

    • @Joe_Brig
      @Joe_Brig 2 ปีที่แล้ว

      @@ambuj.k I use a tool called Karibener on a Mac.

    • @Kalasklister1337
      @Kalasklister1337 2 ปีที่แล้ว +1

      @@ambuj.k On windows you should use autohotkey. Its free and allows you to easily remap any of your keys to do whatever you like. Have not used windows in a few years now but i always liked autohotkey for its simplicity and power. Reason for binding rebinding capslock on OS level is that you use Escape a whole lot and caps lock is basically never used.

  • @KaiBuskirk
    @KaiBuskirk 2 ปีที่แล้ว

    Wow…. Let’s take a look!

  • @arcanelore168
    @arcanelore168 10 หลายเดือนก่อน

    Do you have totorials on that file manger built-in.

  • @HC-nu6xr
    @HC-nu6xr 2 ปีที่แล้ว

    Great video, how did you put a window manager on Debian?

  • @atharva_raje
    @atharva_raje 2 ปีที่แล้ว +2

    But how do I exit it? 😭

    • @DarkGladiator
      @DarkGladiator 2 ปีที่แล้ว

      You must reboot your computer

  • @Jakeu1701
    @Jakeu1701 2 ปีที่แล้ว

    do you cover the sea captians blend?

  • @mrcrackerist
    @mrcrackerist 2 ปีที่แล้ว

    I swapped the tilde key and escape key much nicer then the default location :P

  • @cuzimhappyy7982
    @cuzimhappyy7982 2 ปีที่แล้ว +1

    have you ever looked into Doom Emacs? it uses a vim emulator so the key binds are similar but has more functionality with it being a graphical program (it also has a terminal mode).
    ps. emacs has a ssh client called TRAMP, it can also use sudo.

    • @entelin
      @entelin 2 ปีที่แล้ว +1

      I got interested in emacs for awhile but decided it just wasn't worth it. The main thing emacs has over vim is a decent scripting language and client/server capabilities. Emacs lisp is clearly superior to vimscript, but both languages are slow. That's changing quickly with neovim however and the pace of development in neovim and the wider community of plugins is very high. LUA is far faster, cleaner, and has a large existing user base so many of the advantages of emacs I think will be erased over the next couple years. vi & vim's advantage over emacs has always been that it's a very functional program by default and ubiquitous, with genuinely inspired keybindings. Emacs can be made to be usable, but it's a very serious hobby to get somewhere that is a good experience, and even then the loading times can become genuinely obnoxious. Doom is a good project, and integrating the vim way of doing things certainly helps, but even then it's not all there and mixed with emacs bindings.

  • @camueller28
    @camueller28 2 ปีที่แล้ว

    I like the cheatsheet. Can you make it available for download or did I miss the link somewhere?

  • @Adiusza
    @Adiusza 2 ปีที่แล้ว

    Hi, great video thank you

  • @mirror1766
    @mirror1766 2 ปีที่แล้ว

    For hjkl I feel the same and also have the dislike feeling hand needs to leave home row.. I try to remember 'j' sticks down so is down. Another option is separate learning(and practice use) h and l from learning j and k.

  • @matthieujoly
    @matthieujoly 2 ปีที่แล้ว

    ... and finally, your starting to install all the vim plugin available to most software your using.. browser at least.

  • @ChozoSR388
    @ChozoSR388 ปีที่แล้ว +1

    In order to make things more manageable with my vimrc, I've compartmentalized it; I have a .vim/config/ directory with like my '.vimrc.plug' and '.vimrc.plug.config' and even my '.vimrc.statusline' files, and then the .vimrc file sources them all. A bit more involved to set up initially, but I find it easier to find things.

    • @GiovanniCKC
      @GiovanniCKC ปีที่แล้ว

      This is the good stuff lol, I used to do this too-- you should look into the plugin folder for vim, it'll automatically run all the files in it for you so you don't have to manually get them in ur vimrc and make things even more clean.

  • @xn1kkix
    @xn1kkix 2 ปีที่แล้ว

    Don't heh heh I'll be 50 years old to me Chris, you can do anything you set your mind to, I believe you could get there in several months at most.
    P.S. have you ever played "osu!" ?

  • @vikingthedude
    @vikingthedude 4 หลายเดือนก่อน

    20:52 its all fun and games until you find yourself writing a JJ Abhrams fanfic

  • @bartek...
    @bartek... 2 ปีที่แล้ว

    Is it works on Windows? Is it Visual Studio extension? Do you need virtual linux machine for it? ^.^

    • @astratow
      @astratow ปีที่แล้ว

      You have it with git for windows console, you may install it separately, may use gvim.

  • @Gr00t
    @Gr00t 2 ปีที่แล้ว +2

    My god he's a speed demon.

    • @zeocamo
      @zeocamo 2 ปีที่แล้ว

      who?

  • @pdxdragon7479
    @pdxdragon7479 2 ปีที่แล้ว +1

    I've been an unhappy Windows programmer for two decades. I loved Solaris and vi.
    This brings back happy memories.
    Does Vim still leave ~files around? That bothered me.

    • @mirror1766
      @mirror1766 2 ปีที่แล้ว

      vim is available for windows. you can move where those undesired files are created or disable them being made.

  • @rufine4114
    @rufine4114 2 ปีที่แล้ว +1

    I don't know why
    but I hate VIM with no reason
    gonna watch this video later and I'll see if I will use it or no
    btw, what is the best IDE for shell scripting (please don't recommend sublime cuz I've already used it)??
    edit: vim is OP, and I"m fallen in love with it,
    and for those people who don't use VIM and they wanna learn how to use it, go to the terminal and type "vimtutor" and you'll see kinda free offline VIM course (it works if you have VIM in your computer)
    and for me, VIM is such a great program for editing files that I wanted to write this comment using it but there's no VIM here on TH-cam ;(

    • @GiovanniCKC
      @GiovanniCKC ปีที่แล้ว

      firenvim seems to work with youtube's comment box last I checked ;)

  • @hanshofman
    @hanshofman 2 ปีที่แล้ว

    The absolute Vim editor is Helix, feature complete, no plugins, no electron, tsp, lsp built-in, multi-platform, rust

  • @CoolDudeClem
    @CoolDudeClem 2 ปีที่แล้ว

    Is this how to edit a video on Linux? Just typing a bunch of stuff? I think I'll stick with Windows.

  • @ShiziKroc
    @ShiziKroc 2 ปีที่แล้ว +1

    you could also find global vimrc in /etc/vim/vimrc and uncomment line where it says "open on last edited line" to open where you left off.

  • @donaldmickunas8552
    @donaldmickunas8552 2 ปีที่แล้ว +1

    Chris, Chris, Chris,
    “I’ve only been using vim for a little over a month” 😂😂😂😂😂😂
    What a crock of…….
    I’m one of the people who badgered you into seriously trying vim in the first place when you were doing regular streams over 2 years ago.
    Keep it honest, amigo. Being honest and real were two qualities that got you here. 😉
    Great video otherwise.

    • @ChrisTitusTech
      @ChrisTitusTech  2 ปีที่แล้ว +1

      Yes I opened VIM and used some of the basic commands on that stream, but for the most part all my editing was done in vscode. I've recently moved to almost using VIM exclusively in Linux. Still have vscode in Windows as gVim in Windows is rough as hell.

    • @donaldmickunas8552
      @donaldmickunas8552 2 ปีที่แล้ว +1

      @@ChrisTitusTech yeah, I had to give you the business about that. You just got truly serious about vim recently. Well, you got a break from our badgering at least. LOL

  • @solomontechspin
    @solomontechspin 2 ปีที่แล้ว +2

    aint no way am using VIM Chris NOOOOOOOOOOOOOO

    • @ChrisTitusTech
      @ChrisTitusTech  2 ปีที่แล้ว

      Come to the dark side... it has much power...

    • @zeocamo
      @zeocamo 2 ปีที่แล้ว

      join the dark side and become one with the force.

  • @L0tsen
    @L0tsen 2 ปีที่แล้ว

    what windows manager do you use and how did you get it like that

    • @cenkhocakesitleri
      @cenkhocakesitleri 2 ปีที่แล้ว

      It's bspwm. Also you can get the exact looking, see for "installing my version of linux" video of ChrisTitusTech.

  • @David-135
    @David-135 2 ปีที่แล้ว

    You should do a video on the benefits of using mutt as your email client.

  • @michaelsims7728
    @michaelsims7728 2 ปีที่แล้ว +3

    Many have wondered how to exit Vim lol

    • @zeocamo
      @zeocamo 2 ปีที่แล้ว

      and you do it with :w or :x or :q not ZZ or ZQ as a newbie