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

prepend * to every non-blank line

Prepend an asterisk to every non-blank line in the input file.

Start file
This is a
very short

file, but it is 
still
full

of

surpises.
End file
*This is a
*very short

*file, but it is 
*still
*full

*of

*surpises.

View Diff

1,2c1,2
< This is a
< very short
---
> *This is a
> *very short
4,6c4,6
< file, but it is 
< still
< full
---
> *file, but it is 
> *still
> *full
8c8
< of
---
> *of
10c10
< surpises.
---
> *surpises.

Solutions by @giursino1:

Unlock 14 remaining solutions by signing in and submitting your own entry
Created by: @johnreitano

1525 active golfers, 6245 entries

Solutions by @giursino1:
10
#49 - giursino / @giursino1

03/15/2020 at 12:25PM

10
#>144 - giursino / @giursino1

05/18/2020 at 05:12PM

11
#>482 - giursino / @giursino1

03/15/2020 at 12:24PM

12
#>760 - giursino / @giursino1

03/15/2020 at 12:22PM

13
#>803 - giursino / @giursino1

03/15/2020 at 12:20PM

14
#>840 - giursino / @giursino1

03/15/2020 at 12:19PM

16
#>1000 - giursino / @giursino1

03/15/2020 at 12:18PM

19
#>1186 - giursino / @giursino1

03/15/2020 at 12:09PM

20
#>1251 - giursino / @giursino1

05/18/2020 at 05:10PM

21
#>1303 - giursino / @giursino1

03/15/2020 at 12:08PM

22
#>1348 - giursino / @giursino1

03/15/2020 at 12:04PM

23
#>1394 - giursino / @giursino1

03/15/2020 at 12:07PM

24
#>1421 - giursino / @giursino1

03/15/2020 at 11:28AM

27
#>1457 - giursino / @giursino1

03/15/2020 at 11:35AM