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

Inverting Lines - 1832 entries

A simple challenge to invert all lines, except the first.

  • Best score: 10
  • Best player score: 10
  • Position: #201 / 497
  • Number of attempts: 1
xrandr outputs and dashes - 652 entries

uh oh, different video drivers identify display outputs with more dashes. Quick, need to change this xrandr script!

  • Best score: 12
  • Best player score: 12
  • Position: #13 / 213
  • Number of attempts: 1
Capitalize the Names - 361 entries

I want to capitalize the names in quotes, but just the people's names, not the file names.

  • Best score: 21
  • Best player score: 21
  • Position: #11 / 91
  • Number of attempts: 2
Yo To Hello - 1114 entries

Simply Turn Yo To Hello

  • Best score: 10
  • Best player score: 10
  • Position: #34 / 517
  • Number of attempts: 1
Unsemantic linewrapping - 890 entries

[Inspired by a blog post I read: https://scott.mn/2014/02/21/semantic_linewrapping/. Text adapted.] Sometimes when editing a Markdown file, I wrap the lines semantically. Instead of inserting a newline at 70 columns (or whatever), or making paragraphs one long line, I put in newlines at a point that seems logical to me. This may seem silly, but it produces better diffs. Semantic linewrapping also makes editing snappier. I can delete, edit or insert sentences easily using linewise operations. Code-oriented text editors like Vim and [REDACTED] are really good at this kind of manipulation. Editing text that hasn't been wrapped semantically is a pain, though:

  • Best score: 9
  • Best player score: 9
  • Position: #7 / 224
  • Number of attempts: 1
Add semicolons - 10792 entries

Simply add a semicolon at the end of each line

  • Best score: 10
  • Best player score: 10
  • Position: #138 / 3044
  • Number of attempts: 2
Box it - 7827 entries

Create a box around a line.

  • Best score: 21
  • Best player score: 21
  • Position: #435 / 1864
  • Number of attempts: 1
multiple cursor alternative - 1474 entries

from: https://www.reddit.com/r/vim/comments/6w5pfa/crosspost_from_remacs_how_would_you_do_this_in_vim/

  • Best score: 19
  • Best player score: 20
  • Position: #139 / 376
  • Number of attempts: 4
Just the middle - 11360 entries

Delete the instructions at the top and bottom.

  • Best score: 7
  • Best player score: 7
  • Position: #930 / 4164
  • Number of attempts: 2
Simple addition - 310 entries

The right side of the equation is already there. We just need the left one now.

  • Best score: 12
  • Best player score: 12
  • Position: #25 / 117
  • Number of attempts: 2
Paragraph breaks - 505 entries

Swap the blank lines and the aaa lines.

  • Best score: 10
  • Best player score: 11
  • Position: #74 / 165
  • Number of attempts: 2
comments galore - 998 entries

Basic comment reformatting

  • Best score: 10
  • Best player score: 10
  • Position: #233 / 418
  • Number of attempts: 2
VimGolfNight - 536 entries

Based on "The name of the game".

  • Best score: 12
  • Best player score: 12
  • Position: #272 / 343
  • Number of attempts: 1
Space out the alphabet - 1627 entries

Put 3 spaces between adjacent letters.

  • Best score: 15
  • Best player score: 15
  • Position: #77 / 440
  • Number of attempts: 2
I forgot quotes - 15931 entries

Oops.

  • Best score: 10
  • Best player score: 10
  • Position: #719 / 4161
  • Number of attempts: 2
-a-b-c- - 3176 entries

Put hyphens everywhere.

  • Best score: 13
  • Best player score: 15
  • Position: #658 / 1129
  • Number of attempts: 2
Alphabetize the directory - 283 entries

Put the contacts and their information in alphabetical order.

  • Best score: 30
  • Best player score: 32
  • Position: #37 / 99
  • Number of attempts: 2
Numbering a List - 1859 entries

Pretty simple, number the list.

  • Best score: 13
  • Best player score: 13
  • Position: #19 / 639
  • Number of attempts: 1
Frank Malone
Twitter:

entered into 18 challenges

contributed 0 challenges