Vi and Vim Stack Exchange is a question and answer site for people using the vi and Vim families of text editors. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I love Vim. I spend my whole life using it: At work I develop code with Vim, I edit config files with it, I write my emails with it. At home I write my todo lists and my buckets lists with it. On my free time I write a book in it. I go to meetups about Vim and I try to convince everyone I know to use it (Unfortunately my grandma doesn't agree that she should use it to write letters to her friends).

With all this love for our beloved editor I am facing a huge problem: as a normally constituted human I sometimes want to relax and have fun. Naturally I'd want to do that in our godly editor, but I don't know how I can do that. Of course I have spent hours customizing my color scheme and writing recursive macro that I watch for long time but after six or seven hours straight it is not that fun anymore.

So I'm calling to you fellow Vimmers: How can I have fun in Vim?

share|improve this question
2  
Write a book of jokes, using vim! – loutre yesterday
3  
@loutre: A book of jokes about Vim? Like "Vi has two modes: one where it beeps whenever you hit a key, and one where it deletes all the work you've done." :-) – statox yesterday
2  
I have a lot of fun with Vim, simply by using it efficiently. – romainl yesterday

There's a lot of way to have fun in Vim: for example, one could install the vim-script nibble plugin (this one has a dependency which also must be installed).

Once the plugin is installed the command :Nibble will start a snake game in a new buffer. The snake can be controlled with hjkl and the game can be paused with space. With that it is possible to spend hours of fun in our beloved editor.

nibble for vim


Now if you get bored with the snake you can still play a good old tetris game with TeTrIs.vim.

This one has no dependencies and the game is started with Leaderte

Please admire how beautiful it is:

Tetris in vim


Finally, if you really are a hardcore gamer and still want some new experiences, you could try sokoban. This game asks for too much cerebral skill for me but I'm sure some geniuses will still enjoy it.

share|improve this answer
1  
reminded me of flappyvird - github.com/mattn/flappyvird-vim – sp asic yesterday
    
@spasic: I didn't know it but it totally fits the list! – statox 23 hours ago
    
you could also watch the whole world through the matrix plugin – mMontu 21 hours ago

Imagine a file format for another hobby you have, and write a Vim plugin for it, just for you.

For example, let's say you like to compose crosswords / puzzles. In this case, you could use/create a special file format, and complement it with a plugin that helps or automates certain operations, e.g. easy toggling of a black square, easy navigation from definition to word position in the puzzle, or automatic search in a specified dictionary for incomplete words, based on the current row/column cursor location. Stuff like that :)

(The idea comes from a Emacs book: "Writing GNU Emacs Extensions")

share|improve this answer
4  
Your answer made me think that one could develop a plugin to help create and play regex crosswords like the ones on this site. The plugin could read a crossword and highlight the characters placed wrongly :-) – statox 22 hours ago
    
Yes - anything sufficiently interesting to make the effort worthy :) – VanLaser 21 hours ago
    
@statox, that is an awesome site, thank you for linking to it! :D – Wildcard 10 hours ago

Didn't notice VimGolf listed here, so thought I'd throw it out there:

VimGolf

It's a fun way to challenge yourself to do Vim things in fewer and fewer keystrokes. Apologies if you already knew of it.

share|improve this answer
    
Don't forget about Programming Puzzles & Code Golf! – cat 12 hours ago

Do you think you've mastered Vim? Do you know all the commands? Is using Vim getting boring and a banality? Are you longing for the days when discovering how to quit Vim was exciting and new?

Then level up your Vim to achieve the next level of Vim mastery! It's as simple as using :VimLevelUp!

fun! s:level_up()
    let l:all_mappings = []
    for k in range(33, 123) + [125, 126, 127]
        let l:all_mappings += [nr2char(l:k), '<C-' . nr2char(l:k) . '>']
    endfor
    let l:all_mappings += ['<Bar>', '<Left>', '<Right>', '<Up>', '<Down>']
    let l:all_mappings += ['<C-Bar>', '<C-Left>', '<C-Right>', '<C-Up>', '<C-Down>']
    let l:all_mappings += ['<S-Bar>', '<S-Left>', '<S-Right>', '<S-Up>', '<S-Down>']
    for i in range(1, 12)
        let l:all_mappings += ['<F' . l:i . '>', '<C-F' . l:i . '>', '<S-F' . l:i . '>']
    endfor

    let l:random = map(systemlist('seq 0 ' . (len(l:all_mappings)-1) . ' | shuf'), 'str2nr(v:val)')
    for i in range(0, len(l:all_mappings)-1)
        execute 'nnoremap ' . l:all_mappings[i] . ' ' . l:all_mappings[l:random[i]]
    endfor

    echo "Welcome to level 2"
endfun

command! VimLevelUp :call s:level_up()

This is guaranteed to give you a new way to experience Vim and endless hours of fun!

(Note: uses seq and shuf − it could be ported to BSD and OSX by using jot).

share|improve this answer
1  
So...what does it do? – Wildcard 10 hours ago
    
Not tested, but I'd say it shuffles vim keys randomly. Talk about a steep learning curve... – mdup 10 hours ago

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.