Real Vim ninjas count every keystroke - do you?

Pick a challenge, fire up Vim, and show us what you got.

Changelog, Rules & FAQ, updates: @vimgolf, RSS.

Your VimGolf key: please sign in

$ gem install vimgolf
$ vimgolf setup
$ vimgolf put [challenge ID]

Played Challenges

Reformat/Refactor a Golfer Class - 5527 entries

A simple case of removing unneeded code and fixing broken indentation.

  • Best score: 32
  • Best player score: 42
  • Number of attempts: 2
Split the words - 334 entries

Add the spaces manually if you must, but if you use Vim's spell checking feature wisely, I think you'll save a LARGE number of strokes.

  • Best score: 18
  • Best player score: 41
  • Number of attempts: 1
Hole-in-one - 936 entries

Lets take this golf thing literally.. Drive off the tee into the hole, and of course you don't strike the ball completely clean.

  • Best score: 15
  • Best player score: 25
  • Number of attempts: 1
Whitespace, empty lines and tabs - 2557 entries

Convert tabs to spaces, strip empty lines and trailing whitespace.

  • Best score: 16
  • Best player score: 33
  • Number of attempts: 1
Delete unwanted lines - 336 entries

Delete all lines which does not end in "o.."

  • Best score: 9
  • Best player score: 10
  • Number of attempts: 1
Search and Replace 0 - 4170 entries

Replace every instance of 'aaa' with 'xaaax'.

  • Best score: 12
  • Best player score: 17
  • Number of attempts: 1
Words in parens - 11183 entries

We should all ace this, right?

  • Best score: 14
  • Best player score: 20
  • Number of attempts: 1
Simple text editing with Vim - 10552 entries

Make the pairs of lines match up by making each second line same as first

  • Best score: 13
  • Best player score: 17
  • Number of attempts: 2
quotes inside quotes - 2807 entries

taken from tip 85 of the very good book 'Practical Vim: Edit Text at the Speed of Thought' ! I'd be interested what people use :)

  • Best score: 14
  • Best player score: 17
  • Number of attempts: 1
David Tran
Twitter:

Hello everyone and everyzero. 嬉しいか?(=`ω´=) I operate on languages and use them. Man or machine. What language do you use?

entered into 9 challenges

contributed 0 challenges