Class: PapyTools::CommandeInit

Inherits:
Commande
  • Object
show all
Defined in:
lib/papy-tools/commande.rb

Instance Method Summary collapse

Methods inherited from Commande

instance

Constructor Details

#initializeCommandeInit

Returns a new instance of CommandeInit.



127
128
# File 'lib/papy-tools/commande.rb', line 127

def initialize
end

Instance Method Details

#run(options = {}) ⇒ Object



130
131
132
133
134
135
136
137
# File 'lib/papy-tools/commande.rb', line 130

def run(options={})
    Dir.mkdir("source") unless File.exist?("source")
    Dir.mkdir("output") unless File.exist?("output")
    Dir.mkdir("template") unless File.exist?("template")
    Dir.mkdir("helper") unless File.exist?("helper")
    FileUtils.cp_r TEMPLATE+"/.","template"
    FileUtils.cp_r HELPER+"/.","helper"
end