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 620 remaining solutions by signing in and submitting your own entry
#621 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

621 active golfers, 2968 entries

Leaderboard (lowest score wins):
29
#301 - Clémence / @Clemence_Neoxia

05/31/2016 at 07:41AM

29
#302 - Alonzo / @tolver_a

07/30/2016 at 07:13AM

29
#303 - Zhihong Liu / @pieapple03

02/17/2017 at 02:29AM

30
#304 - Édouard M'tou / @DouardM

10/04/2013 at 01:50PM

30
#305 - James T. Huggett / @Jmeshka

10/05/2013 at 04:04PM

30
#306 - Steve Tjoa / @stevetjoa

10/11/2013 at 07:24PM

30
#307 - lastsseldon / @lastsseldon

11/04/2013 at 01:24AM

30
#308 - pikaren / @REALpikaren

12/21/2013 at 04:04AM

30
#309 - Alexander Borysov / @ab99c5e2

01/08/2014 at 09:06AM

30
#310 - Quota / @Quotad

01/10/2014 at 11:17AM

30
#311 - Olivier Lechevalier / @RageZBla

01/19/2014 at 11:09AM

30
#312 - Starski / @mstarski

01/29/2014 at 12:16PM

30
#313 - John Doe / @bradavan

01/29/2014 at 07:51PM

30
#314 - Jonathan Ellington / @JEllington90

02/02/2014 at 08:26PM

30
#315 - Mario / @MarioPrint

02/03/2014 at 04:13PM

30
#316 - Robert Siemieniec / @rsiemieniec

02/19/2014 at 02:58PM

30
#317 - lukecowell / @lukecowell

03/08/2014 at 02:40PM

30
#318 - Par Narvi / @ParNarvi

04/01/2014 at 03:07PM

30
#319 - Ole Hansen / @0hansen

06/14/2014 at 06:20PM

30
#320 - João Carvalho / @joaoCarvas

07/11/2014 at 10:38AM

30
#321 - madka / @lachrimae_pavan

08/03/2014 at 08:10PM

30
#322 - Zapata / @Incredible_JFP

08/17/2014 at 08:34PM

30
#323 - Matthieu Crapet / @mcr05

03/01/2015 at 11:52AM

30
#324 - dosmanak / @dosmanak

03/09/2015 at 02:54PM

30
#325 - Benny Wong / @bdotdub

04/15/2015 at 08:44PM

30
#326 - Andreas Carben / @meiner_eins

04/26/2015 at 01:30PM

30
#327 - Seth Yoder / @McMire315

06/24/2015 at 07:59PM

30
#328 - Ilya / @evilguc

10/08/2015 at 02:29PM

30
#329 - Mister Knister / @vimgolf_ctrl_x

03/22/2016 at 02:30PM

30
#330 - Omer Lachish / @rauchy

04/17/2016 at 10:15AM