Class: Rbapp::Runner

Inherits:
Thor::Group
  • Object
show all
Includes:
Thor::Actions
Defined in:
lib/rbapp.rb

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.source_rootObject



15
16
17
# File 'lib/rbapp.rb', line 15

def self.source_root
  File.dirname(__FILE__)
end

Instance Method Details

#copy_sample_taskObject



35
36
37
38
# File 'lib/rbapp.rb', line 35

def copy_sample_task
  return unless options.sample?
  copy_file "templates/app/lib/tasks/sample.thor", "#{name}/lib/tasks/sample.thor"    
end

#create_app_fileObject



27
28
29
# File 'lib/rbapp.rb', line 27

def create_app_file
  template('templates/app/lib/app.tt', "#{name}/lib/#{name}.rb")
end

#create_bin_fileObject



19
20
21
# File 'lib/rbapp.rb', line 19

def create_bin_file
  template('templates/app/bin/app.tt', "#{name}/bin/#{name}.rb")
end

#create_gem_fileObject



23
24
25
# File 'lib/rbapp.rb', line 23

def create_gem_file
  template('templates/app/Gemfile.tt', "#{name}/Gemfile")
end

#create_version_fileObject



31
32
33
# File 'lib/rbapp.rb', line 31

def create_version_file
  template('templates/app/lib/app/version.tt', "#{name}/lib/#{name}/version.rb")
end