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 57343555fd77ad227900df4a

Split line with dots

This line is too long, split it.

Start file
class VimGolf
  def split_me
    MyModel.first_method.second_method(arg).third_method(arg.method_one.method_two)
  end
end
End file
class VimGolf
  def split_me
    MyModel
      .first_method
      .second_method(arg)
      .third_method(arg.method_one.method_two)
  end
end

View Diff

3c3,6
<     MyModel.first_method.second_method(arg).third_method(arg.method_one.method_two)
---
>     MyModel
>       .first_method
>       .second_method(arg)
>       .third_method(arg.method_one.method_two)

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 524 remaining solutions by signing in and submitting your own entry
#525 Jinotega / @Jinotega3000 - Score: 89 - 12/29/16 @ 20:54
jjWwi<CR><BS><BS><BS><BS><BS>      jk<BS><BS><Esc>wwwwijk<BS><BS>hi<BS><BS><Esc>i<CR><BS><BS><BS><BS><BS><BS><CR><BS><BS><BS><BS><BS>      <Esc>wwwwwwwwwbbbhi<CR><BS><BS><BS><BS><BS>      <Esc>j:wq<CR>

0 comments


Created by: @Benoit_Tgt

525 active golfers, 1794 entries

Leaderboard (lowest score wins):
25
#451 - PeterGC / @petkusGC

07/17/2016 at 06:13PM

25
#452 - Meninx / @_Meninx_

07/30/2016 at 04:52PM

25
#453 - Marcel Akkerman / @MarcelAkkerman

12/21/2016 at 02:16PM

25
#454 - Paul Inc / @hiniol1982

07/13/2017 at 03:46PM

25
#455 - Ron Alexssen / @Ralexhere

10/16/2017 at 11:19PM

25
#456 - Carl Ward / @doncarlos999

11/17/2017 at 05:36AM

25
#457 - Elias Åström / @ryvnfn

12/27/2017 at 12:57AM

25
#458 - Spacesh1p / @spacesh1pdev

01/19/2018 at 10:06AM

25
#459 - Daniel de Vries / @devries_d

02/07/2018 at 04:29PM

25
#460 - Tim / @timothyscosta

04/02/2018 at 03:33PM

25
#461 - Gabriel Walford / @gtwalford

08/03/2018 at 08:30PM

25
#462 - Coruja Queridinha / @miriamretka

08/22/2018 at 09:29AM

25
#463 - Rasmus Bergström / @JRasmusBm

09/27/2018 at 09:47PM

25
#464 - vg / @vg53210350

10/28/2018 at 11:58PM

25
#465 - Alex Standke / @xanderstrike

01/25/2019 at 06:42PM

25
#466 - Michał Łowicki / @mlowicki

04/18/2019 at 01:48PM

26
#467 - Jon E. Eguiluz / @viroide

05/12/2016 at 02:55PM

26
#468 - Clémence / @Clemence_Neoxia

05/16/2016 at 05:36PM

26
#469 - Chamoda / @chamodac

06/24/2016 at 09:20AM

26
#470 - 王运 / @640138017

07/10/2016 at 04:13PM

26
#471 - Dan Madden / @guthran

07/14/2016 at 07:56PM

26
#472 - Rizart Dokollari / @rdokollari

09/15/2016 at 08:59AM

26
#473 - Koudougou / @OpenPatate

09/23/2016 at 03:01PM

26
#474 - Christoph F. Seelus / @cseelus

10/26/2016 at 04:07AM

26
#475 - Davis Fields / @i301585

11/04/2016 at 03:04AM

26
#476 - Yann / @yannstad

02/19/2017 at 09:23AM

26
#477 - Will Clardy / @quexxon

04/14/2017 at 08:12PM

26
#478 - Rob Smolinski / @scottymcribs

07/04/2017 at 08:15PM

26
#479 - ¬¬¬ ¬¬¬ / @WLq3KGhxohrCPl1

07/09/2018 at 04:17AM

26
#480 - JulianW / @JulianWgs

10/27/2018 at 03:48PM