Sha256: 42a7ab933554ef19a21cac7965d8913a4e5f20f9cfa01fb82150ee0c2c93d62a
Contents?: true
Size: 832 Bytes
Versions: 5
Compression:
Stored size: 832 Bytes
Contents
require 'rbconfig' # This generator bootstraps a Rails project for use with Cucumber class InstallCucumberGenerator < RubiGen::Base DEFAULT_SHEBANG = File.join(Config::CONFIG['bindir'], Config::CONFIG['ruby_install_name']) attr_reader :project_name def initialize(runtime_args, runtime_options = {}) super @project_name = File.basename(File.expand_path(destination_root)) end def manifest record do |m| script_options = { :chmod => 0755, :shebang => options[:shebang] == DEFAULT_SHEBANG ? nil : options[:shebang] } m.directory 'features/steps' m.template 'env.rb', 'features/steps/env.rb' m.directory 'tasks' m.file 'cucumber.rake', 'tasks/cucumber.rake' end end protected def banner "Usage: #{$0} cucumber" end end
Version data entries
5 entries across 5 versions & 1 rubygems