igrigorik/vimgolf is tracked by TopGit as an open-source project, with 778 stars on GitHub, written primarily in Ruby. Real Vim ninjas count every keystroke - do you?
Snapshot summary built from the project's own GitHub metadata — there's no written TopGit review yet. The page will update automatically when a full review is published.
WHY NO REVIEW YET
TopGit writes full reviews for the most-starred, most-requested repositories. This page is a snapshot until then — see the READ ME tab for the original README in full.
Real Vim ninjas count every keystroke - do you? Head on over to vimgolf.com, pick a challenge, and show us what you've got!
Each challenge provides an input file, and an output file
Your goal is to modify the input file such that it matches the output
Once you install the vimgolf CLI, pick a challenge, open a prompt and put away!
When you launch a challenge from the command line, it will be downloaded from the site and a local Vim session will be launched, which will log every keystroke you make. Once you're done, simply :wq (write and quit) the session and we will score your input and upload it back to the site!
Setup & Play
$> gem install vimgolf
(Go to vimgolf.com, sign in, and grab your API key)
$> vimgolf setup
(Pick a challenge on vimgolf.com)
$> vimgolf put [challenge ID]
Golfing without ruby installation: use docker
$> docker run --rm -it -e "key=YOUR_VIMGOLF_KEY" ghcr.io/filbranden/vimgolf challenge_ID
Playing from other editors
Emacs
There's a lightly maintained interface to play VimGolf challenges in Emacs
over at vimgolf.el
VimGolf.com web app
# start local server
$> bundle exec unicorn -c config/unicorn.rb -E development
# deploy to Heroku
$> git push heroku master
Run tests
Go to the root folder and run bundle exec rake.
How to contribute
This part is for people not familliar with ruby ecosystem
Installation
You need:
ruby
gem bundler
sqlite3 (library version 3.25 or newer, on your local system); or
postgresql
ruby
You need a ruby version, same as .ruby-version
I recommend using rbenv, see https://github.com/rbenv/rbenv to install and manage ruby version.
cd $VIMGOLF_PATH
rbenv install
bundler
Bundler is a gem that aim to manage gem per project.
gem install bundler:1.17.2
Then you need all gems for the apps
bundle install
Using sqlite3 for development (and testing)
It is possible to get a fully functionnal app running locally using SQLite3 only. This is the default adapter for development and testing (it makes for easier ramp up, since you don't need to set up an instance of Postgres and create the appropriate users.)
Note that due to the use of SQL window functions, you need an SQLite3 library version 3.25 or newer installed on your system. The Ruby gem will use the locally installed library, so that is a pre-requisite to using SQLite3. The SQLite3 library shipped on Ubuntu 18.04 is too old, the one on Ubuntu 20.04 is new enough.
Using Postgres for development
You can also use a Postgres database for development (and testing.)
Install and start a Postgres instance running locally on your development host.
The app will run under your user, so create a Postgres user with the same name as your local user and give that user the ability to create databases. This is usually accomplished with the following command:
sudo -u postgres createuser -d $(whoami)
When running any of the Ruby and Rails code, in order to use the Postgres adapter in the development and test environments, export environment variable DATABASE_ADAPTER=pg.
The database names configured will be vimgolf_development and vimgolf_test for the respective environments.
Seed database
Read db/seeds.rb to understand parameters to define how many users, challenges and entries to create.
When creating a local development database on SQLite3 (the default adapter), use the following procedure:
# make the index page works - create collection "challenges"
bundle exec rails db:drop db:setup
# or add many challenges users and entries
bundle exec rails db:drop db:setup challenges=40 users=30 entries=20
When creating a local development database on Postgres, do not use the db:setup and db:reset targets, as those targets rely on loading the db/schema.rb file, but that file contains a schema dump compatible with the SQLite3 database and would possibly produce a broken setup under Postgres. Instead, use db:migrate and db:migrate:reset to create the database running through the Rails migrations as appropriate.
Yes — igrigorik/vimgolf ships under the MIT license, which makes its source code freely readable (and, depending on license terms, forkable and reusable). Source: github.com/igrigorik/vimgolf.
What is igrigorik/vimgolf?
igrigorik/vimgolf (igrigorik/vimgolf) is a Ruby project on GitHub. From the project's own README: Real Vim ninjas count every keystroke - do you?
What license does igrigorik/vimgolf use?
igrigorik/vimgolf is released under the MIT license. Always verify the LICENSE file directly on GitHub for the authoritative terms — license strings can be edited out of sync with a project's actual stance.
Where can I see igrigorik/vimgolf in action?
The project maintains a homepage at http://www.vimgolf.com/. The README tab on this page also usually contains screenshots and a quickstart.
Where do I read more about igrigorik/vimgolf?
This TopGit page is a snapshot — the READ ME tab shows the project's own README content (links stripped, images preserved). The GitHub repository at github.com/igrigorik/vimgolf is the definitive source.
Read full README in the tab above.
Curious whether vimgolf is right for you?
Let ChatGPT, Claude, or Perplexity look into it — click below and see what AI actually says about vimgolf.