Sha256: 3facfcb53d6a0519b34f8c11bdf449b49e7bad19be09cf34f3ada31fd303a331

Contents?: true

Size: 643 Bytes

Versions: 1

Compression:

Stored size: 643 Bytes

Contents

#!/usr/bin/env ruby
require 'rubygems'
require 'optparse'

$:.unshift File.join(File.dirname(__FILE__), '..', 'lib')
require 'routespec'

module RoutespecOpt 
  def self.command
    OptionParser.new do |opts|
      opts.banner = "Routespec #{Routespec::VERSION}"
      opts.on("-i", "--init", "setup routespec in ./spec") do |x|
        if Routespec::Dyr.init
          puts "made spec/routespec"
        else
          puts "spec/routespec already exists"
        end
        return
      end    

      opts.on("-h", "--help", "Show this message") do
        puts opts
        return
      end
    end.parse!
  end
end

RoutespecOpt.command

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
routespec-0.0.1 bin/routespec