chef-zero 5.1.1 → 5.2.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
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d3b24181f44a02acb72212f6b506ba88c611aecc
|
4
|
+
data.tar.gz: d28e1d99c8803fedf8f1ba9ece631f2ae7829195
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ccd7ed569ad1958ccaee60cf4acdff8d9ce87b146a6dd5a12f9b9df294122a1e86c183f5501405d92b73d5221d9bcbf0411987b08c8d18e16e4ed67aa9094e48
|
7
|
+
data.tar.gz: '00997addd10b1aa6a98d8fca3a3aa084a2926135dc4894014dc0e1a06e403a4030271bd6ca569753b8120124da91056396123ce8f93d63efdf2bae287e7a9ab5'
|
@@ -29,18 +29,16 @@ module ChefZero
|
|
29
29
|
|
30
30
|
def self.metadata_from(directory, name, version, recipe_names)
|
31
31
|
metadata = PretendCookbookMetadata.new(PretendCookbook.new(name, recipe_names))
|
32
|
-
# If both .rb and .json exist, read .
|
33
|
-
|
34
|
-
|
35
|
-
|
32
|
+
# If both .rb and .json exist, read .json
|
33
|
+
if has_child(directory, "metadata.json")
|
34
|
+
metadata.from_json(read_file(directory, "metadata.json"))
|
35
|
+
elsif has_child(directory, "metadata.rb")
|
36
36
|
begin
|
37
37
|
file = filename(directory, "metadata.rb") || "(#{name}/metadata.rb)"
|
38
38
|
metadata.instance_eval(read_file(directory, "metadata.rb"), file)
|
39
39
|
rescue
|
40
40
|
ChefZero::Log.error("Error loading cookbook #{name}: #{$!}\n #{$!.backtrace.join("\n ")}")
|
41
41
|
end
|
42
|
-
elsif has_child(directory, "metadata.json")
|
43
|
-
metadata.from_json(read_file(directory, "metadata.json"))
|
44
42
|
end
|
45
43
|
result = {}
|
46
44
|
metadata.to_hash.each_pair do |key, value|
|
@@ -16,7 +16,7 @@ module ChefZero
|
|
16
16
|
|
17
17
|
def matches_doc?(doc)
|
18
18
|
case @operator
|
19
|
-
when "-", "NOT"
|
19
|
+
when "-", "NOT", "!"
|
20
20
|
!operand.matches_doc?(doc)
|
21
21
|
when "+"
|
22
22
|
# TODO This operator uses relevance to eliminate other, unrelated
|
@@ -27,7 +27,7 @@ module ChefZero
|
|
27
27
|
|
28
28
|
def matches_values?(values)
|
29
29
|
case @operator
|
30
|
-
when "-", "NOT"
|
30
|
+
when "-", "NOT", "!"
|
31
31
|
!operand.matches_values?(values)
|
32
32
|
when "+"
|
33
33
|
# TODO This operator uses relevance to eliminate other, unrelated
|
data/lib/chef_zero/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: chef-zero
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 5.
|
4
|
+
version: 5.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- John Keiser
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2017-01-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: mixlib-log
|
@@ -302,7 +302,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
302
302
|
version: '0'
|
303
303
|
requirements: []
|
304
304
|
rubyforge_project:
|
305
|
-
rubygems_version: 2.6.
|
305
|
+
rubygems_version: 2.6.9
|
306
306
|
signing_key:
|
307
307
|
specification_version: 4
|
308
308
|
summary: Self-contained, easy-setup, fast-start in-memory Chef server for testing
|