license-acceptance 1.0.19 → 2.0.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 8383c0bafd2717c7ff9f2af1b0cc6a28b83acb5001150249734e4194a927297a
4
- data.tar.gz: 798ba0cdf60a7bd4e6ca8b680eeec5039eeca8caff3a993e48d3fded2875fa37
3
+ metadata.gz: eee8ab3bdb6b370c3b0c2dddb7a86f22cea5240eae5df17e58e4c367fc08a0fe
4
+ data.tar.gz: 7f25c5f59f833808115dead1157b33f09c9fe4e4000c3c4e70dee586466d74a9
5
5
  SHA512:
6
- metadata.gz: df6e3ccef39dcfef85a6928954cd76d2b9e3ce574291a92f368080fe1594a56b9e30fe5a43ad224994b17ce930bc21cf21a5b2dbdfb3e877e267715ef6ac200e
7
- data.tar.gz: 98a5f5e51bf72821399458d4c07f9acc6c0ba69eafe748c8d0bb34c60fec62fe06582430a4cce829fdf6bbef9c1a21b3c7ddb9df4367645410ff6af8fa5134f2
6
+ metadata.gz: ef3af6247b87811c3796838e707d47b153c7828160a4dee699b3e95f2bef534c055fa34e828548a7e0dc9830b146014c2a8a7a4ac2cca4d94388e180d4fa5581
7
+ data.tar.gz: aa6d132e77ecfb95a8c4e263d29d7731a44f2c8d40d4cd7eeb48fbf8964c5a9e807c6cde3fec5f757af3cb9de2e5fbfc1e8d60c5729598f204fa2829d6e1c42c
data/Gemfile CHANGED
@@ -4,3 +4,25 @@ git_source(:github) { |repo_name| "https://github.com/#{repo_name}" }
4
4
 
5
5
  # Specify your gem's dependencies in license-acceptance.gemspec
6
6
  gemspec
7
+
8
+ group :development do
9
+ gem "chefstyle", "1.2.1"
10
+ gem "climate_control", "~> 0.2"
11
+ gem "mixlib-cli", "~> 1.7"
12
+ gem "rake", ">= 10.1.0"
13
+ gem "rspec", "~> 3.0"
14
+ gem "thor", ">= 0.20", "< 2.0" # validate 2.0 when it ships
15
+ end
16
+
17
+ group :docs do
18
+ gem "yard"
19
+ gem "redcarpet"
20
+ gem "github-markup"
21
+ end
22
+
23
+ group :debug do
24
+ gem "pry"
25
+ gem "pry-byebug"
26
+ gem "pry-stack_explorer", "~> 0.4.0" # pin until we drop ruby < 2.6
27
+ gem "rb-readline"
28
+ end
@@ -76,7 +76,7 @@ module LicenseAcceptance
76
76
  @acceptance_value = accepted_silent? ? ACCEPT_SILENT : ACCEPT
77
77
  true
78
78
  elsif config.output.isatty && prompt_strategy.request(missing_licenses) do
79
- # We have to infer the acceptance value if they use the prompt to accept
79
+ # We have to infer the acceptance value if they use the prompt to accept
80
80
  if config.persist
81
81
  @acceptance_value = ACCEPT # rubocop: disable Lint/AssignmentInCondition
82
82
  file_strategy.persist(product_relationship, missing_licenses)
@@ -1,6 +1,6 @@
1
1
  begin
2
2
  require "mixlib/cli"
3
- rescue => exception
3
+ rescue
4
4
  raise "Must have mixlib-cli gem installed to use this mixin"
5
5
  end
6
6
 
@@ -1,6 +1,6 @@
1
1
  begin
2
2
  require "thor"
3
- rescue => exception
3
+ rescue
4
4
  raise "Must have thor gem installed to use this mixin"
5
5
  end
6
6
 
@@ -18,10 +18,11 @@ module LicenseAcceptance
18
18
  if other.id == id &&
19
19
  other.pretty_name == pretty_name &&
20
20
  other.filename == filename &&
21
- other.mixlib_name == mixlib_name
22
- other.license_required_version == license_required_version
21
+ other.mixlib_name == mixlib_name &&
22
+ other.license_required_version == license_required_version
23
23
  return true
24
24
  end
25
+
25
26
  false
26
27
  end
27
28
 
@@ -7,7 +7,7 @@ require "timeout"
7
7
  module LicenseAcceptance
8
8
  module Strategy
9
9
 
10
- # Interactive prompt for accepting and persistnce license acceptance, or failing with custom exit code
10
+ # Interactive prompt for accepting and persistence license acceptance, or failing with custom exit code
11
11
  class Prompt < Base
12
12
  include Logger
13
13
 
@@ -78,7 +78,7 @@ module LicenseAcceptance
78
78
  q.modify :down, :trim
79
79
  q.required true
80
80
  q.messages[:required?] = "You must enter 'yes' or 'no'"
81
- q.validate /^\s*(yes|no)\s*$/i
81
+ q.validate(/^\s*(yes|no)\s*$/i)
82
82
  q.messages[:valid?] = "You must enter 'yes' or 'no'"
83
83
  end
84
84
  end
@@ -1,3 +1,3 @@
1
1
  module LicenseAcceptance
2
- VERSION = "1.0.19".freeze
2
+ VERSION = "2.0.0".freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: license-acceptance
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.19
4
+ version: 2.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - tyler-ball
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-04-14 00:00:00.000000000 Z
11
+ date: 2020-08-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: pastel
@@ -44,160 +44,28 @@ dependencies:
44
44
  requirements:
45
45
  - - "~>"
46
46
  - !ruby/object:Gem::Version
47
- version: '0.3'
47
+ version: '0.6'
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
- version: '0.3'
54
+ version: '0.6'
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: tty-prompt
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
59
  - - "~>"
60
60
  - !ruby/object:Gem::Version
61
- version: '0.18'
61
+ version: '0.20'
62
62
  type: :runtime
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
66
  - - "~>"
67
- - !ruby/object:Gem::Version
68
- version: '0.18'
69
- - !ruby/object:Gem::Dependency
70
- name: rake
71
- requirement: !ruby/object:Gem::Requirement
72
- requirements:
73
- - - "~>"
74
- - !ruby/object:Gem::Version
75
- version: '13.0'
76
- type: :development
77
- prerelease: false
78
- version_requirements: !ruby/object:Gem::Requirement
79
- requirements:
80
- - - "~>"
81
- - !ruby/object:Gem::Version
82
- version: '13.0'
83
- - !ruby/object:Gem::Dependency
84
- name: rspec
85
- requirement: !ruby/object:Gem::Requirement
86
- requirements:
87
- - - "~>"
88
- - !ruby/object:Gem::Version
89
- version: '3.0'
90
- type: :development
91
- prerelease: false
92
- version_requirements: !ruby/object:Gem::Requirement
93
- requirements:
94
- - - "~>"
95
- - !ruby/object:Gem::Version
96
- version: '3.0'
97
- - !ruby/object:Gem::Dependency
98
- name: pry
99
- requirement: !ruby/object:Gem::Requirement
100
- requirements:
101
- - - "~>"
102
- - !ruby/object:Gem::Version
103
- version: '0.12'
104
- type: :development
105
- prerelease: false
106
- version_requirements: !ruby/object:Gem::Requirement
107
- requirements:
108
- - - "~>"
109
- - !ruby/object:Gem::Version
110
- version: '0.12'
111
- - !ruby/object:Gem::Dependency
112
- name: pry-byebug
113
- requirement: !ruby/object:Gem::Requirement
114
- requirements:
115
- - - "~>"
116
- - !ruby/object:Gem::Version
117
- version: '3.6'
118
- type: :development
119
- prerelease: false
120
- version_requirements: !ruby/object:Gem::Requirement
121
- requirements:
122
- - - "~>"
123
- - !ruby/object:Gem::Version
124
- version: '3.6'
125
- - !ruby/object:Gem::Dependency
126
- name: pry-stack_explorer
127
- requirement: !ruby/object:Gem::Requirement
128
- requirements:
129
- - - "~>"
130
- - !ruby/object:Gem::Version
131
- version: '0.4'
132
- type: :development
133
- prerelease: false
134
- version_requirements: !ruby/object:Gem::Requirement
135
- requirements:
136
- - - "~>"
137
- - !ruby/object:Gem::Version
138
- version: '0.4'
139
- - !ruby/object:Gem::Dependency
140
- name: mixlib-cli
141
- requirement: !ruby/object:Gem::Requirement
142
- requirements:
143
- - - "~>"
144
- - !ruby/object:Gem::Version
145
- version: '1.7'
146
- type: :development
147
- prerelease: false
148
- version_requirements: !ruby/object:Gem::Requirement
149
- requirements:
150
- - - "~>"
151
- - !ruby/object:Gem::Version
152
- version: '1.7'
153
- - !ruby/object:Gem::Dependency
154
- name: thor
155
- requirement: !ruby/object:Gem::Requirement
156
- requirements:
157
- - - ">="
158
67
  - !ruby/object:Gem::Version
159
68
  version: '0.20'
160
- - - "<"
161
- - !ruby/object:Gem::Version
162
- version: '2.0'
163
- type: :development
164
- prerelease: false
165
- version_requirements: !ruby/object:Gem::Requirement
166
- requirements:
167
- - - ">="
168
- - !ruby/object:Gem::Version
169
- version: '0.20'
170
- - - "<"
171
- - !ruby/object:Gem::Version
172
- version: '2.0'
173
- - !ruby/object:Gem::Dependency
174
- name: climate_control
175
- requirement: !ruby/object:Gem::Requirement
176
- requirements:
177
- - - "~>"
178
- - !ruby/object:Gem::Version
179
- version: '0.2'
180
- type: :development
181
- prerelease: false
182
- version_requirements: !ruby/object:Gem::Requirement
183
- requirements:
184
- - - "~>"
185
- - !ruby/object:Gem::Version
186
- version: '0.2'
187
- - !ruby/object:Gem::Dependency
188
- name: chefstyle
189
- requirement: !ruby/object:Gem::Requirement
190
- requirements:
191
- - - ">="
192
- - !ruby/object:Gem::Version
193
- version: '0'
194
- type: :development
195
- prerelease: false
196
- version_requirements: !ruby/object:Gem::Requirement
197
- requirements:
198
- - - ">="
199
- - !ruby/object:Gem::Version
200
- version: '0'
201
69
  description: Chef End User License Agreement Acceptance for Ruby products
202
70
  email:
203
71
  - tball@chef.io
@@ -235,7 +103,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
235
103
  requirements:
236
104
  - - ">="
237
105
  - !ruby/object:Gem::Version
238
- version: '2.3'
106
+ version: '2.4'
239
107
  required_rubygems_version: !ruby/object:Gem::Requirement
240
108
  requirements:
241
109
  - - ">="