Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
branch: master
Fetching contributors…

Cannot retrieve contributors at this time

91 lines (66 sloc) 2.559 kb

Ruby application generator

A Thor based generator to rapidly create a Ruby project with all the infrastructure setup for testing, mocking etc.

  • Jeweler to create basic gem setup
  • Binaries in \bin if --binaries
  • Project library files in /lib
  • Cucumber features, step definitions and basic configurations
  • Rspec2 specs with configurations
  • Unit tests
  • Shoulda tests
  • Mock libraries: mocha, flex, rr, rspec
  • Autotest with grock and fsevent
  • Bundler configuration for gem management
  • Require DSL using require-me gem
  • RCov for test coverage
  • Heckle for test mutations


It can be installed as a thor task:

$ thor install lib/application.thor

Alternatively install it as a gem and use the binary. $ gem install rubyapp


To run it as a thor task: $ thor ruby:app my-ruby-app [options]

Alternatively run it using the binary $ rubyapp my-ruby-project [options]


You can define system wide default options for ruby apps you create (your preferred framework stack) in a ~/.rubyapp file. The ~* implies ENV['HOME], the environment variable "HOME" on any system. Any options you call the program with explicitly will override the defaults in this file.

The options --rspec2, --cucumber, --license, --autotest, and --bundler are all set to true unless explicitly disabled either in the .rubyapp file or using the negation option when rubyapp is run (see negating boolean options below).

Boolean options: To negate a boolean option prefix it with no-, fx --no-rspec2 to disable rspec2 from the project infrastructure creation.

Rubyproject currently supports the following boolean options:


String options: --mock-lib --factory-lib

Mock-lib: Valid mock-lib values: rspec, mocha, flexmock, rr

Example: $ rubyapp my-ruby-mock-project --mock-lib flexmock

Factory-lib: Valid factory-lib values: factory_girl, machinist, object_daddy, blueprints

Example: $ rubyapp my-ruby-mock-project --factory-lib factory_girl


Please feel free to fork this project or provide suggestions for improvements, bug fixes etc.

Share and enjoy!

Copyright (c) 2010, Kristian Mandrup

Jump to Line
Something went wrong with that request. Please try again.