Live data from Hacker News

Intermediate Vim

dn.ht

111–120 of 130 posts

Re: Intermediate Vim

#111
post #104

Earlier quoted context omitted.

We were taught to touch type in grade school, but I goofed off during those lessons. I got through college without needing it. I was a speedy point-and-peck typist, which was good enough for that period of my life. Later on, when I learned to program, I found that my slow typing speed frequently caused me to lose my train of thought midway through a line of code. It was frustrating enough that I spent a month teachin…

Mind if I asked which course/website you used to learn how to type properly?

I learned on https://www.typing.com/ (typingweb.com when I did it). One thing it doesn't do well is special characters and numbers though. We need a typing course for coders.

e.g. How fast can we type the below accurately?

function typing_test($foo = 'bar') { return $foo }

Re: Intermediate Vim

#112

“If you’re like me and never learned to touch type properly, just use the arrow keys, it’s fine, don’t worry about it.” Are touch typists rare these days? I feel like people these days forego even learning to type properly. I dont understand why they refuse to just learn it, it is such an essential skill to have.

We were taught to touch type in grade school, but I goofed off during those lessons. I got through college without needing it. I was a speedy point-and-peck typist, which was good enough for that period of my life. Later on, when I learned to program, I found that my slow typing speed frequently caused me to lose my train of thought midway through a line of code. It was frustrating enough that I spent a month teachin…

> I don't look at the keyboard anymore

You might more than you think. That was the case for me. Rearranging the key caps on my (non-laptop) keyboard quickly cured that, and is an interesting exercise when you can afford it.

Re: Intermediate Vim

#113

Maybe you can cover macros since they are conceptually very simple and very powerful. They may seem a bit complex but are quite simple. Basically you just record your editing movements and play it back. How macros work: press q x to record and q to end. Then repeat with @ x, where x is the name of the macro you want to use (you can have several macros). Anything you do will be played back. That's it... Conceptually s…

[deleted]

Re: Intermediate Vim

#114
post #104

Earlier quoted context omitted.

We were taught to touch type in grade school, but I goofed off during those lessons. I got through college without needing it. I was a speedy point-and-peck typist, which was good enough for that period of my life. Later on, when I learned to program, I found that my slow typing speed frequently caused me to lose my train of thought midway through a line of code. It was frustrating enough that I spent a month teachin…

Mind if I asked which course/website you used to learn how to type properly?

Idea for someone looking for something to build, on my list but probably won't prioritize it for many years as I'll build it eventually but would welcome someone else building it. If anyone wants to work on this ping me and maybe I can help collaborate/mentor.

Typing App for Engineers, MVP:

* Load a canvas with a preloaded code snippet, the text is mostly greyed out

* When typing your text shows over the greyed out text, but darker, red if the character doesn't match

* Time how long it takes to type it perfectly

Gold plating:

* Users can login

* Users can upload own code snippets for community contributions

* Leaderboard shows top times and users for those who typed it perfectly, only perfect scores are registered, because code must be perfect or it won't run.

This could also allow an engineer to learn APIs while learning to type. I did this with 60 or so pages of Drupal code a few years ago. I used Compiz fusion's overlay opacity control to put a loaded code snippet into VIM,reduced the opacity of the window slightly, then laid another VIM terminal on top of it, reduced the opacity of that terminal window so I could see behind it and started typing the slightly greyed out text from the window behind.

Been meaning to put this out on my blog but this is a good start.

Re: Intermediate Vim

#115

“If you’re like me and never learned to touch type properly, just use the arrow keys, it’s fine, don’t worry about it.” Are touch typists rare these days? I feel like people these days forego even learning to type properly. I dont understand why they refuse to just learn it, it is such an essential skill to have.

I learned touch typing when I was 25. THis was probably after 6 years of programming and computer use. I could already type fast enough without looking at the keyboard, but I decided to learn anyway.YMMV, but it took me about 2hours for 5 days to get comfortable with touch typing. For programmers who are still wondering the effort required, just do it!

For me the biggest advantage I see after learning touch typing is lesser errors because you are getting proper feedback from the screen while you are typing.

Re: Intermediate Vim

#116

“If you’re like me and never learned to touch type properly, just use the arrow keys, it’s fine, don’t worry about it.” Are touch typists rare these days? I feel like people these days forego even learning to type properly. I dont understand why they refuse to just learn it, it is such an essential skill to have.

I (finally) learned to touch type after picking up a Microsoft ergonomic keyboard a couple years back. Really forced me into touch typing since there was a clear division between each hand.

Prior to that, I could type at a very decent speed and pseudo touch typed: I would put my fingers on home row but quickly I would lose that discipline and look at my hands as I typed and use the wrong fingers for various keys. I'm guessing that most people who are using VIM (or just programming on a daily basis) are close enough to count even if it isn't proper touch typing like I had in the past

That being said, I'm SOO much faster than I used to be and would encourage people to grab an ergonomic keyboard. Better for your body and it forces you to type properly :D

Re: Intermediate Vim

#117
post #54

The balloon comparison is strange. I would've just said that adding shift to a shortcut often reverses it... / for search and ? for search backwards, alt-tab to switch windows, alt-shift-tab to go the other way, ctrl-tab to go to next tab in Firefox, ctrl-shift-tab for backwards. It's incredibly common.

So common, that cars shift into reverse!

Re: Intermediate Vim

#118
post #92

After years of using Vim, I recently learned that I could use `Ctrl+C` instead of `ESC` to get back to command mode. Mind blown.

Holy crap really?!?

Man, that'll definitely save my pinky from cramping up every so often.

Re: Intermediate Vim

#119

Earlier quoted context omitted.

For that example I would open the document in Sublime Text, select all, and split selection into lines so that I have an independent caret on every line. Then I'd just type the quote at the beginning and end of each line - the home/end keys will put each caret at the beginning or end of its respective line.

I've been using vim a lot recently. Multiple cursors for this exact scenario is the only thing I still miss about other editors. Macros and other solutions are great, but for this very simple and surprisingly common task, multiple cursors are perfect.

Multiple cursors has been supported for quite some time now in VSCode, as well as related useful default editor shortcuts like jump cursor by word, beginning/end of line, etc, that are especially useful when moving around multiple cursors/selections simultaneously.

Re: Intermediate Vim

#120

“If you’re like me and never learned to touch type properly, just use the arrow keys, it’s fine, don’t worry about it.” Are touch typists rare these days? I feel like people these days forego even learning to type properly. I dont understand why they refuse to just learn it, it is such an essential skill to have.

I'm a pretty decent touch-typist, but I have some hiccups when using the symbols on the number bar (@#$%^ etc), or brackets, or other stuff that's common when programming but uncommon in most texts used by touch-typing programs.

So I wrote a little program to download source code from Github and allow you to type along with it, and measure the number of typos. It's super old, half-finished and was one of the projects I used to learn Python, so the code is hot garbage and unmaintained, but it might be an interesting thing to look at and use if anyone wants to practice touch-typing on source code:

https://github.com/bcbrown/CodeTyper

Hell, if anyone's interested in using it, maybe I'll pick it back up and improve it.

Post reply on HN