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 5c26181de8c649000cfcac17

Change part of a function name in multiple occurrences

Change the middle part of the function name in multiple places, preferably using the next and dot commands.

Start file
call_this_function()

_this_
  
  call_this_function()

 _this_

 call_this_function()
End file
call_that_function()

_this_
  
  call_that_function()

 _this_

 call_that_function()

View Diff

1c1
< call_this_function()
---
> call_that_function()
5c5
<   call_this_function()
---
>   call_that_function()
9c9
<  call_this_function()
---
>  call_that_function()

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 125 remaining solutions by signing in and submitting your own entry
#126 Nick Lucent / @NickLucent - Score: 26 - 02/22/19 @ 07:21
:%s/l_this_f/l_that_f/g<CR>ZZ

0 comments


#127 Phoon / @justflashhim - Score: 26 - 05/10/19 @ 16:27
:%s/l_this_f/l_that_f/g<CR>ZZ

0 comments


Created by: @xiongyuwu

127 active golfers, 380 entries

Leaderboard (lowest score wins):
15
#61 - sjcomp / @sjcomp

02/26/2019 at 07:08PM

15
#62 - Titouan Teyssier / @TitouanT_

03/01/2019 at 09:27PM

15
#63 - Groovy / @groovy9

03/07/2019 at 09:23PM

15
#64 - chenqiqi / @chenqiqi13

03/13/2019 at 06:27AM

15
#65 - enji / @enji_ja

03/18/2019 at 08:54PM

15
#66 - Parsa Amini / @ParsaAmini

03/19/2019 at 06:37PM

15
#67 - Grant / @grant_7788

04/28/2019 at 12:04AM

15
#68 - Arno / @arnoxmp

05/22/2019 at 10:55AM

15
#69 - Nick Yeow / @nickyeow

05/22/2019 at 12:13PM

15
#70 - mkaminaga / @mkmng3

06/08/2019 at 04:27AM

15
#71 - duyanh.y4n.pham / @PhamY4n

06/12/2019 at 03:09PM

16
#72 - omrisarig / @omrisarig

12/28/2018 at 04:53PM

16
#73 - Dany Alexander Caro Saavedra / @DanyAlexanderC7

12/28/2018 at 09:32PM

16
#74 - Alex Standke / @xanderstrike

12/28/2018 at 11:59PM

16
#75 - TimMcGuire / @mcguire

12/31/2018 at 10:28PM

16
#76 - Aru / @IAmAru

01/01/2019 at 02:58AM

16
#77 - Gilad Slonim / @SlonimGilad

01/01/2019 at 07:20PM

16
#78 - Slawek Ligus / @ooz_ie

01/03/2019 at 05:54AM

16
#79 - daveramirez / @daveramirez

01/03/2019 at 09:29PM

16
#80 - Francisco Magalhães / @FranciscoMags

01/06/2019 at 06:20PM

16
#81 - antoine mas / @aneomas

01/09/2019 at 09:47AM

16
#82 - Mat / @matpbo

01/09/2019 at 05:06PM

16
#83 - melts / @melts

01/09/2019 at 08:54PM

16
#84 - Will / @obiwan__k3n00bi

01/10/2019 at 12:36AM

16
#85 - Dmatrix / @Dr_Dmatrix

01/10/2019 at 06:28PM

16
#86 - hbdgr / @t_hbdgr

01/14/2019 at 10:18PM

16
#87 - wrglprmft / @wrglprmft

01/19/2019 at 08:49PM

16
#88 - Dominic Z / @thammaaa

02/01/2019 at 02:04PM

16
#89 - Michael Aquilina / @mikeaquilina4

02/02/2019 at 09:43PM

16
#90 - sfmogway / @sfmogway

02/14/2019 at 12:59PM