diff options
author | Alexandre IGNJATOVIC <alexandre.ignjatovic@doctolib.com> | 2018-10-04 13:14:26 +0200 |
---|---|---|
committer | Alexandre Ignjatovic <alexandre.ignjatovic@gmail.com> | 2018-10-04 20:58:14 +0200 |
commit | a245100e1e2ecb4bba2209a3ca1f9a3744be7cc9 (patch) | |
tree | 7e01aa3bc58ff1714da2468cb6b29579bc7b108b | |
parent | 9a8182d5559395f0b1b36bafd62af6e5a626ad8c (diff) | |
download | chef-a245100e1e2ecb4bba2209a3ca1f9a3744be7cc9.tar.gz |
better docs for Chef::Knife::Bootstrap#validate_options!
Signed-off-by: Alexandre Ignjatovic <alexandre.ignjatovic@gmail.com>
-rw-r--r-- | lib/chef/knife/bootstrap.rb | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/lib/chef/knife/bootstrap.rb b/lib/chef/knife/bootstrap.rb index 19a7d6543e..bdeee3394b 100644 --- a/lib/chef/knife/bootstrap.rb +++ b/lib/chef/knife/bootstrap.rb @@ -409,7 +409,13 @@ class Chef end end - # make sure policyfile values are set correctly + # Ensure options are valid by checking policyfile values. + # + # The method call will cause the program to exit(1) if: + # * Only one of --policy-name and --policy-group is specified + # * Policyfile options are set and --run-list is set as well + # + # @return [TrueClass] If options are valid. def validate_options! if incomplete_policyfile_options? ui.error("--policy-name and --policy-group must be specified together") |