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 524e1a20b81fe50002000008

attr_aligner

Two attr keywords. Two separate indentations. Align the colons.

Start file
attr_reader :align, :variables, :with
attr_accessor :spaces, :to, :complete, :challenge
# vim: set expandtab:
End file
attr_reader :align,
            :variables,
            :with
attr_accessor :spaces,
              :to,
              :complete,
              :challenge
# vim: set expandtab:

View Diff

1,2c1,7
< attr_reader :align, :variables, :with
< attr_accessor :spaces, :to, :complete, :challenge
---
> attr_reader :align,
>             :variables,
>             :with
> attr_accessor :spaces,
>               :to,
>               :complete,
>               :challenge

Solutions

The best way to learn is to practice. Below, you will find some of the solutions other golfers have entered. To unlock higher ranked solutions, submit your own entry which does as well or better than the solutions you can currently see - climb the ladder!

Check out these helpful resources to improve your Vim skills... Game on.

Unlock 637 remaining solutions by signing in and submitting your own entry
#638 ren / @wxoc - Score: 134 - 02/10/14 @ 07:05
f,a<CR><C-C><C-C>f,a<CR>j<C-H><C-C><C-C>jf,<CR>kf,a<CR><C-C><C-C>f,a<CR><C-C><C-C>f,<CR>klf,a<CR><C-C><C-C>ggvjjj=vgG<C-V><Esc>jlllllllli<Tab><C-C><C-C>ui    <C-C><C-C>jhhhi    <C-C><C-C>jjhhhi      <C-C><C-C>jhhhhhi      <C-C><C-C>jhhhhhi      <C-C><C-C>:wq<CR>

0 comments


Created by: @udioica

638 active golfers, 3072 entries

Leaderboard (lowest score wins):
28
#271 - I / @ForgetIt17

10/22/2013 at 03:15PM

28
#272 - まっすー。 / @trapple

10/31/2013 at 02:42AM

28
#273 - Zifei Tong / @chevalun

12/06/2013 at 11:06AM

28
#274 - Kent Frazier / @mindredefined

12/07/2013 at 05:39AM

28
#275 - digitalronin / @digitalronin

12/07/2013 at 02:46PM

28
#276 - Alessandro Lisander / @wuiimu

01/04/2014 at 06:13PM

28
#277 - mattsalacain / @mattsalacain

01/30/2014 at 09:16PM

28
#278 - Yongho / @YONG_HO

02/04/2014 at 01:51AM

28
#279 - Trader / @bolatrade

02/13/2014 at 09:36PM

28
#280 - Lucius L. Hilley III / @unkmar

02/27/2014 at 08:38AM

28
#281 - brett / @brettyukich

03/23/2014 at 06:43PM

28
#282 - ところたん / @tokoro10g

04/06/2014 at 01:29PM

28
#283 - zmo / @guyzmo

05/08/2014 at 12:13PM

28
#284 - Partial SHA1 hash / @25fcag9e

06/06/2014 at 06:50PM

28
#285 - Edric Garran / @edric_garran

06/18/2014 at 12:25AM

28
#286 - Alexey Fedorov / @waterlink000

07/09/2014 at 06:26PM

28
#287 - Michi Loro / @michiloro

07/15/2014 at 11:39AM

28
#288 - Dash / @DashJungle

07/19/2014 at 11:00PM

28
#289 - Tj / @yrddy

08/13/2014 at 06:03AM

28
#290 - Oli Lalonde / @o_lalonde

01/11/2015 at 06:04PM

28
#291 - Evan Coleman / @edc1591

04/15/2015 at 09:20PM

28
#292 - Josh Balloch / @ballouchebag

04/18/2015 at 02:17AM

28
#293 - Faat / @i_faat

01/29/2016 at 03:27PM

28
#294 - Austin Wood / @indiesquidge

02/16/2016 at 06:01PM

28
#295 - vim golf wolfe / @vimwolfe

11/06/2016 at 12:49AM

28
#296 - sijinyuan / @sijinyuan

02/17/2017 at 02:02AM

28
#297 - Harsh Kumar / @datsleepyguy

09/09/2017 at 02:44PM

28
#298 - Frank Rifk / @r1fk

09/02/2018 at 07:27PM

29
#299 - n.st / @0013901644043f9

10/04/2013 at 05:37AM

29
#300 - James / @Dronak

10/07/2013 at 02:43PM