create shared target options for executable

Signed-off-by: Dominik Richter <dominik.richter@gmail.com>
This commit is contained in:
Dominik Richter 2015-09-23 02:07:56 +02:00
parent 12e09b2218
commit 0e63ba7e4a

View file

@ -42,9 +42,7 @@ class VulcanoCLI < Thor
end
end
desc 'exec PATHS', 'run all test files'
option :id, type: :string,
desc: 'Attach a profile ID to all test results'
def self.target_options
option :target, aliases: :t, type: :string, default: nil,
desc: 'Simple targeting option using URIs, e.g. ssh://user:pass@host:port'
option :backend, aliases: :b, type: :string, default: nil,
@ -69,6 +67,12 @@ class VulcanoCLI < Thor
desc: 'Allow remote scans with WinRM to run on self-signed certificates.'
option :winrm_ssl, type: :boolean, default: false,
desc: 'Configure WinRM scans to run via SSL instead of pure HTTP.'
end
desc 'exec PATHS', 'run all test files'
option :id, type: :string,
desc: 'Attach a profile ID to all test results'
target_options
option :format, type: :string, default: 'progress'
def exec(*tests)
runner = Vulcano::Runner.new(options)