Librarian::Cli
# File lib/librarian/puppet/cli.rb, line 21 def init copy_file environment.specfile_name if File.exists? ".gitignore" gitignore = File.read('.gitignore').split("\n") else gitignore = [] end gitignore << ".tmp/" unless gitignore.include? ".tmp/" gitignore << "modules/" unless gitignore.include? "modules/" File.open(".gitignore", 'w') do |f| f.puts gitignore.join("\n") end end
# File lib/librarian/puppet/cli.rb, line 47 def install unless File.exist?('Puppetfile') say "Could not find Puppetfile in #{Dir.pwd}", :red exit 1 end ensure! clean! if options["clean"] unless options["destructive"].nil? environment.config_db.local['destructive'] = options['destructive'].to_s end if options.include?("strip-dot-git") strip_dot_git_val = options["strip-dot-git"] ? "1" : nil environment.config_db.local["install.strip-dot-git"] = strip_dot_git_val end if options.include?("path") environment.config_db.local["path"] = options["path"] end environment.config_db.local['mode'] = options['local'] ? 'local' : nil resolve! debug { "Install: dependencies resolved"} install! end
Generated with the Darkfish Rdoc Generator 2.