8 ms·
I don't know how this would work out ergonomically. My dad is a cab driver and he often complains that pressing the clutch with his foot often giving him RSI ki
by kamaal 14y ago
I don't know how this would work out ergonomically. My dad is a cab driver and he often complains that pressing the clutch with his foot often giving him RSI kind of pain.
But however I think this is purely subjective. From an experiment perspective, this is really cool! And this generally qualifies into what could one call a 'real hack'. This has a air of freshness to it.
Now the real power of vim is in getting into a mode called 'extreme keyboarding'. I didn't realize this until I read Tom Christiansen's seminal essay "Zenclavier: Extreme Keyboarding"- http://oreilly.com/news/zenclavier_1299.html http://oreilly.com/news/zenclavier_1299.html
This is to ultimately turn the keyboard into a Musical instrument, and then to become 'one with the keyboard'. Totally loosing any realization that you are actually typing. Read the essay carefully and try to understand how he tries to talk about 'moving in and out of zones'.
I started learning vim a few days back, after I suffered from Emacs Pinky. When I started question I asked was, 'Why should I memorize so many commands'. The thing is I quickly realized that being proficient with vim, requires you to understand some things. You really have to understand the vim paradigm, without that straightly diving into vim wont be much productive.
You have to learn h,j,k,l are not just navigational keys but also can be combined with multipliers like 20h(Moves 20 positions to the left). You basically speak a 'Editor programming language'. You program editor with a stream of characters. Like for example you my say 'copy this line, move up 20 positions and paste it'. This will be yy(copy current line) 20k(Move up 20 positions) p(paste it there).
So you have to basically learn these things in detail. You can use position stuff for things as well. Like for example 'd' specifies 'cut from here' and 'y' specifies 'yank/copy from here', but to where? the next character specifies that for example '$' specifies the end of a line. You can also do something like 'y2/foo' this means 'yank from here till foo'. You will have to learn regular expressions, touch typing, and many other text processing stuff. Basically you learn a terse programming language which is written as a stream of characters with data on the editor as a input.
Recently a colleague of mine introduced me to a editor command called ': perldo' you can do perl oneliner on the editor line by line.
The only thing is I couldn't find a book so far in my early days of vim, which completely teaches the 'zen of vim' completely in the paradigm, in which one needs to understand it. So vim is really about these things, I don't how far the pedal/clutch experiments gel with this concept. You may need a totally different editor paradigm to work with this setup.
In the meanwhile, if someone knows of a book that talks of vim in the way its supposed to be explained please recommend. All I could find on the net was cheat sheets, books that teach a commands in bulk.
- elliottkember 14y ago>> I don't know how this would work out ergonomically. My dad is a cab driver and he often complains that pressing the clutch with his foot often giving him RSI kind of pain. I think the car clutch is more related to the force required to press it - it's kind of a long, slow push with lots of pressure AND control at the same time. This seems like a button, on/off-type deal - more like tapping your foot than squeezing a clutch.
- weaksauce 14y agoYou can start thinking in vim by reading this answer on stack overflow: http://stackoverflow.com/a/1220118 http://stackoverflow.com/a/1220118 Moving word wise,(w,e) is used a lot. Next occurrence of word under cursor is useful. *,# Learning effective macros is extremely useful. di" is one of my favorite commands. Delete everything inside the quotes not including the quotes. Put inoremap jj <Esc> into your .vimrc so that you can press jj quickly in insert mode instead of Esc. Remap your arrow keys to nop and get proficient with it; this feels like I am editing super fast. A lot of editor time can be spent with your hands on home row without ever leaving.
- ehsanu1 14y agodi" is one of my favorite commands. Delete everything inside the quotes not including the quotes. You usually want to replace what's inside the quotes, so hence use ci" cit is pretty nice for replacing a tag's inner html. And of course this works with parentheses - ci( - and brackets - ci[ - and curly braces and single quotes and angle brackets.. I love vim :)
- weaksauce 14y agoYeah you are right; I use c more than d. The a command is also very useful.
- orthecreedence 14y agoWow cit...I've been wondering if this exists for a year now. I remember reading about it when I first started learning vim but it somehow eluded me afterwards. Thanks! I use ci{ all the time for functions and CSS. It's like magic. Whenever I'm using something like nano, I'll instinctively type what looks like a long string of gibberish: "jjjddo [oh crap] <bs><bs>..." Once you really start getting used to the language, it makes it frustrating to use anything else.