Skip to content
This repository

RedGreen clone (colorful rake spec) for RubyMotion's Bacon with a couple styles. Includes Autotest functionality, an applescript to make your iOS sim headless, and a ported terminal color library you may use with NSLog.

branch: master

Fetching latest commit…


Cannot retrieve the latest commit at this time

Octocat-spinner-32 app
Octocat-spinner-32 resources
Octocat-spinner-32 spec
Octocat-spinner-32 .gitignore
Octocat-spinner-32 Gemfile
Octocat-spinner-32 Gemfile.lock
Octocat-spinner-32 Guardfile
Octocat-spinner-32 Rakefile


RedGreen clone (colorful rake spec) for RubyMotion. The project includes a ported version of ansiterm & can auto-test using Guard.

The motion-redgreen Gem

Please see for the gem version! Thank you Vladimir for creating the gem!

Github Pages URL


  • Autotest functionality with Guard
  • A ported ansiterm.rb for terminal colors
  • 3 styles of colorized Bacon output (00-redgreen.rb)
  • nearly-headless iOS Simulator via an AppleScript in the Guardfile


  • Copy 00-redgreen.rb into spec/
  • Load rm-ansiterm.rb in your app/
  • Run rake spec

For using Guard I have prepared a Gemfile & Guardfile

  • Add the Gemfile & Guardfile to your project
  • Run bundle install
  • Run guard
  • Red, green, refactor!

Output Styles

There are currently 3 styles, settable at the top of 00-redgreen.rb

Default style is :focused


# string.rb
class String
  def method_missing(sym, *args, &block)
    Term::ANSIColor.send(sym) { self } rescue super
# kernel.rb
class Kernel
  def p(arg, style=nil)
    if Term.nil?
      NSLog arg
      NSLog(style ? arg.send(style) : arg)

With code like the above, you can do colorful NSLog output in this way:

p "I like Cyan", :cyan
p "Sometimes this is hard to read...", :blue
p [{:oh=>"this"}, "is", :convenient].inspect, :yellow

Pull requests are appreciated!

Something went wrong with that request. Please try again.