14 ms·
This is cool and all, but nearly useless for any experienced vimmer. I almost never press `i` to enter insert mode, and I don't expect most vimmers to do so ei
by Slackwise 6y ago
This is cool and all, but nearly useless for any experienced vimmer.
I almost never press `i` to enter insert mode, and I don't expect most vimmers to do so either. My most common ways to enter insert mode are, off the top of my head...
o -- Open new line below current line, enter insert mode.
O -- Open new line above current line, enter insert mode.
ci( -- Delete all text between the nearest parenthesis and enter insert mode within the parens.
A -- Jump to end of line and enter insert mode.
I -- Jump to start of line and enter insert mode.
C -- Delete to end of line, enter insert mode.
cc -- Delete entire current line and enter insert mode.
ctX -- Delete to the character X where X is whatever character I see ahead of my cursor that I want to delete up to, and leave me in insert mode.
cfX -- Same as ctX except include the found character in the deletion, then enter insert mode.
- atty 6y agoSeems like you just need more pedals.
- deleted 6y ago[deleted]
- aufhebung 6y agoHey, maybe we could put these pedals somewhere more accessible. Like under your fingers.
- fengyangzhou 6y agolol
- medstrom 6y agoWell, what makes thumb keys so great is that the thumbs are particularly independent of what your other fingers are doing. Foot switches fill the same purpose. You can only have so many keys under your other fingers, and the more you add, the more movement will be required of your hand.
- nuker 6y agoVim should support mouse, like Midnight Commander
- harry8 6y ago:set mouse=a And away you go. As you get more efficient at vim use you might find you want to turn that off again. (and also without the colon in your vimrc file if you want it to stick)
- HouseOfStairs 6y agoIn general yes, but there are still some cases where mouse is better than the equivalent keys. Mainly resizing splits (guess how many lines you want and then C-w <size>|, vs just dragging the divider). :set ttymouse=sgr also makes it a lot smoother.
- gmfawcett 6y agoYou can do it with one pedal -- just tap out your preferred option in Morse.
- cardamomo 6y agoOne of these bad boys should do the trick. https://www.nordkeyboards.com/products/nord-pedal-keys-27 https://www.nordkeyboards.com/products/nord-pedal-keys-27 But maybe you'd be more efficient with a chording setup...
- elihu 6y agoOrgan pedals would work for that. I think typically those just use magnets and reed switches (when connected electronically rather than mechanically). Not to be confused with reed organs, which usually just have one big pedal that operates the bellows. Though sometimes they also have levers you can push to the side with your knee.
- kiwidrew 6y agoImagine that with emacs: it's easy! Simply double-clutch the "Ctrl" and "Super" pedals while pressing Alt+Shift+T on the keyboard to open a new block context and auto-indent to the correct tab stop. ;)
- mauvehaus 6y ago"Granny shifting when you should've been double clutching..."
- pkulak 6y agoI still don't understand why you would double clutch a Honda Civic. Especially if you were trying to like, go real fast.
- jsjohnst 6y agoIf you double clutch near redline on your RPMs, you can get marginally faster gear changes with less wear on your synchronizers.
- pkulak 6y agoDouble clutching is changing into neutral, then into the target gear, right? How could that be faster?
- jsjohnst 6y agoTry it (shifting at high RPMs, specifically near redline) in a Honda Civic (or any other decent, but not higher end car) and you’ll see. Shift at normal RPM ranges and you’d be right to feel doubtful it would be faster.
- mauvehaus 6y agoUpshifting, it isn't usually necessary, though I'm not a street racer, so I can't comment on the validity of that particular quote [0]. Downshifting, particularly into first as you're coming to a stop sign, it'll save a fair amount of wear on the synchros. Or if you have a car with worn synchros, it'll help ensure a quicker, smoother downshift in general. A 5-3 downshift on an offramp usually benefits, for instance. [0] Given the substantial liberties they took in general, your skepticism might be justified.
- kapakos 6y agoI’m thinking of pedals that a pipe organ has.
- keithnz 6y agoseems like it would be awfully slow for any experienced vimmer also. Seems like a really bad idea for a foot pedal / vim integration. A, possibly, much better idea would be if you press the pedal, is turn the hjkl keys into sending actual arrow key keycodes so those annoying times when you need to arrow through OS menus etc you can use your vim instincts. Not that I'd ever want to incorporate a foot pedal myself, but seems like a better use. Vims keyboard drive approach is super quick as is, if you are having trouble with getting into and out of insert mode, maybe Vim isn't for you.
- Shared404 6y ago> if you are having trouble with getting into and out of insert mode, maybe Vim isn't for you. I've got a question there actually. The only thing that throws off my flow while using Vim is exiting insert mode, as my keyboard has an inconvenient esc key. Is there a better way to exit? I've done some cursory looking but haven't found anything that looks useful. (Remapping my keyboard isn't a viable option, as I game on my machine sometimes, and occasionally need weirdly specific keys.)
- jolmg 6y agoCtrl-C and Ctrl-[ also work by default, but personally I use CapsLock after doing `setxkbmap -option caps:escape`. > Remapping my keyboard isn't a viable option, as I game on my machine sometimes You can also map something specifically on vim with :imap/:vmap/:cmap.
- ilostmymangoman 6y agoPlease note that Ctrl-C does not do the same thing as Esc or Ctrl-[. More info: https://unix.stackexchange.com/questions/53633/does-using-ctrlc-instead-of-esc-to-exit-insert-mode-break-anything-in-vi https://unix.stackexchange.com/questions/53633/does-using-ct...
- jolmg 6y ago> Quit insert mode, go back to Normal mode. Do not check for abbreviations. Does not trigger the InsertLeave autocommand event. Well, it's the same if neither you nor a plugin uses abbreviations nor InsertLeave. Also, if you don't need that particular behavior of <C-c>, you can do `:map <C-c> <Esc>` to make it behave exactly the same.
- ggop 6y agoMinor improvement, cc can be replaced by S
- CGamesPlay 6y agoIs shift-S faster than cc? The keys are farther away from each other, but I guess you can get some bonus by pressing them "in parallel"... For me, cc feels faster. Although I might feel differently if it was, say pp vs shift-S.
- jolmg 6y ago> Is shift-S faster than cc? The keys are farther away from each other In my case, my left pinky rests on the shift and my left ring-finger rests on the "s", so shift-S is just pressing the keys my fingers are already resting on.
- gmfawcett 6y agoYour pinky rests on the shift key? My touch-typing teacher would have smacked my fingers with a ruler. :)
- jolmg 6y agoI guess it's a habit from using the left Shift (and left Ctrl) a lot more frequently than the "A". If I just used the keyboard for writing text, perhaps resting on "A" would make more sense for me.
- gmfawcett 6y agoNothing wrong with that! Some of us were indoctrinated to rest our hands in a certain way, no matter what kind of typing we do. :)
- artificialLimbs 6y agocc keeps {my} cursor at the current indent. S does not.
- jolmg 6y agoce - change to end of word (consecutive identifier chars or consecutive punctuation) cE - change to end of WORD (consecutive non-whitespace chars) Those are probably the most common for me because I tend to navigate by word/WORD in a line with w, b, W, B.
- bobbyi_settv 6y agoI need to get in the habit of using those. I tend to do ct<space>
- bamboozled 6y agoBeen using vim for 20 years and didn’t know some of these, thanks.
- emidln 6y agoI use cw and Cw a lot, but the point is made, c is more useful than "some delete op" + "insert mode".
- jolmg 6y agoI think you meant cW. Cw deletes 'till end of line then inserts a "w".
- marcodiego 6y agoI think 3 pedals are suggested: I, i and A
- myth2018 6y agoI've been using Vim regularly for the last six years and I still learn new, basic things. Thanks for that.
- kazinator 6y agoMoreover, where is the concurrency? I mean, you cannot start typing until you're in insert mode. The i<text>ESC are serialized. How is it faster if the i and ESC are foot operated? You can't start typing until the pedal is down. You can't lift the pedal until you've finished the entry, and you can't give a command until the pedal is up.
- pkulak 6y agoC??? And I've been doing c$ for years like a chump!
- mrweasel 6y agoI’ve been using $a, well ESC $a just to be sure
- stcont 6y agoTo add to this ci works for all sorts of things like [ { < “ ‘ etc. There’s also di (delete in) and vi (visual select in) and probably a ton of others that I don’t know about. I’ll never know all of the wonderful ways to use vim
- yesbabyyes 6y agoAnd cit inside (html, xml) tags. And then there's a for around -- cat, daw, >a{...
- bobbyi_settv 6y agoci also can take a number for nesting level. For example, c2i( will change within the second level of surrounding parens rather than the innermost