Class: ModuleSync::CLI::Base
- Inherits:
-
Thor
- Object
- Thor
- Thor
- ModuleSync::CLI::Base
show all
- Defined in:
- lib/modulesync/cli.rb
Instance Method Summary
collapse
Methods inherited from Thor
#_invalid_command_call, exit_on_failure?, start
Instance Method Details
#execute(*command_args) ⇒ Object
180
181
182
183
184
|
# File 'lib/modulesync/cli.rb', line 180
def execute(*command_args)
raise Thor::Error, 'COMMAND is a required argument' if command_args.empty?
ModuleSync.execute CLI.prepare_options(options, command_args: command_args)
end
|
#update ⇒ Object
143
144
145
146
147
148
149
150
|
# File 'lib/modulesync/cli.rb', line 143
def update
config = CLI.prepare_options(options)
raise Thor::Error, 'No value provided for required option "--message"' unless config[:noop] \
|| config[:message] \
|| config[:offline]
ModuleSync.update config
end
|