class Grundstein::Runner
Entry point for the command line interface.
Public Instance Methods
add(generator_name)
click to toggle source
# File lib/grundstein/runner.rb, line 18 def add(generator_name) generator = Generator::Loader.new(generator_name) generator.run rescue Generator::GeneratorError => e puts "ERROR: #{e.to_s.c_error}" # TODO: ask stuff (https://github.com/JEG2/highline) # e.g.: gitignore will ask you if your intend to use Vagrant or Ruby or C... end
list()
click to toggle source
# File lib/grundstein/runner.rb, line 8 def list Generator::Repository.instance.generators.each do |name| gen = Generator::Loader.new(name) puts " #{gen.name.ljust(20).c_gen} #{gen.desc}" end rescue Generator::GeneratorError => e puts "ERROR: #{e.to_s.c_error}" end