Call Montréal, Canada 524-949-6869

Blog

Saturday, March 5, 2011

Trigger Cucumber Features from Vim

I use rstakeout to automatically run my Cucumber features when a feature changes (yes I probably should be using watchr). I use the following command:

rstakeout "rake cucumber:wip" "features/**/*"

But sometimes I want to run the features manually. However, I don't want to leave my editor to do this. A mapping in Vim to trigger the run saves the day:

map <Leader>c :call system("touch features/support/env.rb")<CR>

Developing Ruby on Rails applications and custom Content Management Systems in Montréal. Contact Firsthand.