mirror of
https://github.com/inspec/inspec
synced 2024-11-10 07:04:15 +00:00
Updated to use Inspec.deprecate instead of log to deprecate the --hook option
Signed-off-by: Vasu1105 <vasundhara.jagdale@chef.io>
This commit is contained in:
parent
a3feab0943
commit
6a45164e87
2 changed files with 6 additions and 1 deletions
|
@ -120,6 +120,11 @@
|
|||
"object_classes": {
|
||||
"action": "warn",
|
||||
"suffix": "These classes will be removed in InSpec 5.0."
|
||||
},
|
||||
"cli_option_hook":{
|
||||
"action": "warn",
|
||||
"prefix": "The --hook option is being replaced by the --activator option.",
|
||||
"suffix": "This options will be removed in InSpec 4.0."
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -32,7 +32,7 @@ module InspecPlugins
|
|||
|
||||
# Handle deprecation of option --hook
|
||||
unless options[:hook].nil?
|
||||
Inspec::Log.warn("Use --activator on the command line instead of --hook. --hook option will be deprecated in future.")
|
||||
Inspec.deprecate "cli_option_hook"
|
||||
options[:activator] = options.delete(:hook)
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue