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 591903ff3060ed0b32000007

Adam's challenge

Change both normal to bold and 4 by 2. Adam Wathan challenge this on twitter . He did it in 11 keystrokes on Sublime.

Start file
<div>
    <span class="text-base text-dark wt-normal">
        @icon('line-graph', 'icon-sm text-dark-faint m-r-4') ${{ number_format($product->totalRevenue() / 100) }}
    </span>
    <span class="text-base text-dark wt-normal">
        @icon('users', 'icon-sm text-dark-faint m-r-4') {{ $product->totalPurchases() }}
    </span>
</div>
End file
<div>
    <span class="text-base text-dark wt-bold">
        @icon('line-graph', 'icon-sm text-dark-faint m-r-2') ${{ number_format($product->totalRevenue() / 100) }}
    </span>
    <span class="text-base text-dark wt-bold">
        @icon('users', 'icon-sm text-dark-faint m-r-2') {{ $product->totalPurchases() }}
    </span>
</div>

View Diff

2,3c2,3
<     <span class="text-base text-dark wt-normal">
<         @icon('line-graph', 'icon-sm text-dark-faint m-r-4') ${{ number_format($product->totalRevenue() / 100) }}
---
>     <span class="text-base text-dark wt-bold">
>         @icon('line-graph', 'icon-sm text-dark-faint m-r-2') ${{ number_format($product->totalRevenue() / 100) }}
5,6c5,6
<     <span class="text-base text-dark wt-normal">
<         @icon('users', 'icon-sm text-dark-faint m-r-4') {{ $product->totalPurchases() }}
---
>     <span class="text-base text-dark wt-bold">
>         @icon('users', 'icon-sm text-dark-faint m-r-2') {{ $product->totalPurchases() }}

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 251 remaining solutions by signing in and submitting your own entry
#252 Krystle / @krystle_test - Score: 55 - 05/17/17 @ 06:32
:%s/t<BS>wt-normal/wt-bold<CR><Down><Right>i:w<BS><BS><Esc>:w%<BS><BS><BS>:%s/r-4/r-2<CR><Esc>:wq<CR>

0 comments


Created by: @TresErresCo

252 active golfers, 904 entries

Leaderboard (lowest score wins):
18
#91 - Maxim / @alfa101

01/08/2020 at 04:58AM

18
#92 - floyd / @floyd10086

04/21/2020 at 06:05AM

18
#93 - Moatvald / @moatvald

05/27/2020 at 07:30AM

18
#94 - hepebexè / @hepebexe

12/31/2020 at 10:04PM

18
#95 - Jung Yeon Park / @park_jungy

01/14/2021 at 03:56PM

19
#96 - we’re going to need a bigger bot / @assaflavie

05/18/2017 at 06:24PM

19
#97 - mattp (part of the 💉💉 club) / @mattpep

05/22/2017 at 03:05PM

19
#98 - Léo Ercolanelli / @ercolanellileo

05/23/2017 at 09:27PM

19
#99 - Christian Abbott / @etopixi

05/30/2017 at 11:02AM

19
#100 - Adriano Benin / @adrianob11

06/06/2017 at 02:48PM

19
#101 - toddagibson / @toddagibson

06/08/2017 at 01:28AM

19
#102 - kanazawak / @_kanazawak

06/13/2017 at 03:49PM

19
#103 - Super VedoVatto / @supervedovatto

06/18/2017 at 12:39PM

19
#104 - Christian Stammen / @c0smiq

06/21/2017 at 08:43AM

19
#105 - Nathan Gober / @thegobernador

06/30/2017 at 01:06PM

19
#106 - SirVimGolf / @SirVimGolf

08/23/2017 at 09:12PM

19
#107 - bazkila@gmail.com / @bazkila

09/03/2017 at 04:18AM

19
#108 - QingyuZhao / @zhao_qingyu

11/21/2017 at 07:14AM

19
#109 - Arijus / @argshook

02/09/2018 at 09:02AM

19
#110 - Lisa Ugray / @lisa_ugray

03/16/2018 at 01:50PM

19
#111 - Aunt Jovie / @auntjovie

05/23/2018 at 08:06PM

19
#112 - Norbert / @mullno

06/26/2018 at 06:20PM

19
#113 - Brendan B Amdocs / @AmdocsB

11/02/2018 at 05:42PM

19
#114 - Vimfiz / @vimfiz

03/29/2019 at 11:05PM

19
#115 - james_bunch / @james_bunch

05/04/2019 at 04:43AM

19
#116 - Chester Yap / @Chest_ErYap

07/22/2019 at 12:06PM

19
#117 - Lory / @Lory46845742

11/14/2019 at 07:52AM

19
#118 - countime / @countime1

03/13/2020 at 08:56AM

19
#119 - 薛浩滎 / @iTPChbTeI4ZW9s3

03/17/2020 at 11:00PM

19
#120 - Ming Dai / @MingDai2

07/01/2020 at 04:55PM