mixlib-cli 2.1.6 → 2.1.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/mixlib/cli.rb +3 -3
- data/lib/mixlib/cli/formatter.rb +1 -1
- data/lib/mixlib/cli/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d4d1591454c7940424cf9b65bc490f10e651dfd09a54effab6665bcdb08d5d60
|
4
|
+
data.tar.gz: 8225a500779099fa3f0b7103a396f428dadccbd24b393acd8b3a2523c4e6212a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: dc73cfd3404053a3fbf661a217a7198957677e3e229d143f95b1d69cf5da5f8f534835979a8b0979b07ad7f979e4245e34b1522d96b1c94a48197aab0a370c79
|
7
|
+
data.tar.gz: 9e3ace92718b1a365ca18ed1e12b0d4a945ae38b2c417b45188f0982626fbaa679d383ff5f7c82ab59f695d842fba669776bfe69a90ed36759e189f375d537b5
|
data/lib/mixlib/cli.rb
CHANGED
@@ -16,7 +16,7 @@
|
|
16
16
|
# limitations under the License.
|
17
17
|
#
|
18
18
|
|
19
|
-
require "optparse"
|
19
|
+
require "optparse" unless defined?(OptionParser)
|
20
20
|
require_relative "cli/formatter"
|
21
21
|
module Mixlib
|
22
22
|
|
@@ -140,7 +140,7 @@ module Mixlib
|
|
140
140
|
# and converts it to a value suitable for the new option.
|
141
141
|
# If not provided, the value provided to the deprecated option will be
|
142
142
|
# assigned directly to the converted option.
|
143
|
-
# keep<Boolean> :: Defaults to true, this
|
143
|
+
# keep<Boolean> :: Defaults to true, this ensures that `options[:deprecated_flag]` is
|
144
144
|
# populated when the deprecated flag is used. If set to false,
|
145
145
|
# only the value in `replacement` will be set. Results undefined
|
146
146
|
# if no replacement is provided. You can use this to enforce the transition
|
@@ -194,7 +194,7 @@ module Mixlib
|
|
194
194
|
# === Returns
|
195
195
|
# @options<Hash>:: The current options hash.
|
196
196
|
def options=(val)
|
197
|
-
raise(ArgumentError, "Options must
|
197
|
+
raise(ArgumentError, "Options must receive a hash") unless val.is_a?(Hash)
|
198
198
|
|
199
199
|
@options = val
|
200
200
|
end
|
data/lib/mixlib/cli/formatter.rb
CHANGED
data/lib/mixlib/cli/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mixlib-cli
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.1.
|
4
|
+
version: 2.1.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Chef Software, Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-08-21 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: A simple mixin for CLI interfaces, including option parsing
|
14
14
|
email: info@chef.io
|