Module: R10K::CLI

Defined in:
lib/r10k/cli.rb,
lib/r10k/cli/deploy.rb,
lib/r10k/cli/module.rb,
lib/r10k/cli/version.rb,
lib/r10k/cli/puppetfile.rb,
lib/r10k/cli/environment.rb,
lib/r10k/cli/synchronize.rb

Defined Under Namespace

Modules: Deploy, Environment, Module, Puppetfile, Synchronize, Version

Class Method Summary collapse

Class Method Details

.commandObject



9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
# File 'lib/r10k/cli.rb', line 9

def self.command
  @cmd ||= Cri::Command.define do
    name    'r10k'
    usage   'r10k <subcommand> [options]'
    summary 'Killer robot powered Puppet environment deployment'
    description "      r10k is a suite of commands to help deploy and manage puppet code for\n      complex environments.\n    EOD\n\n    flag :h, :help, 'Show help for this command'\n    flag :t, :trace, 'Display stack traces on application crash'\n\n    optional :v, :verbose, 'Set verbosity level' do |value, cmd|\n      case value\n      when true\n        R10K::Logging.level = 'INFO'\n      when String\n        R10K::Logging.level = value\n      end\n    end\n\n    required :c, :config, 'Specify a global configuration file (deprecated, use `r10k deploy -c`)' do |value, cmd|\n      logger.warn \"Calling `r10k --config <action>` as a global option is deprecated; use r10k <action> --config\"\n    end\n\n    run do |opts, args, cmd|\n      puts cmd.help(:verbose => opts[:verbose])\n      exit 0\n    end\n  end\nend\n"