Class: ConfigCurator::CLI
- Inherits:
-
Thor
- Object
- Thor
- ConfigCurator::CLI
- Defined in:
- lib/config_curator/cli.rb
Overview
Thor class for the curate
command.
Instance Method Summary collapse
-
#install(manifest = 'manifest.yml') ⇒ Boolean
Installs the collection.
Instance Method Details
#install(manifest = 'manifest.yml') ⇒ Boolean
Installs the collection.
20 21 22 23 24 25 26 27 28 29 30 31 32 |
# File 'lib/config_curator/cli.rb', line 20 def install(manifest = 'manifest.yml') unless File.exist? manifest logger.fatal { "Manifest file '#{manifest}' does not exist." } return false end collection.load_manifest manifest result = [:dryrun] ? collection.install? : collection.install msg = (result, [:dryrun]) result ? logger.info(msg) : logger.error(msg) result end |