halite 1.0.4 → 1.0.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/lib/halite/spec_helper/patcher.rb +10 -1
- data/lib/halite/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9c04dc8c5f3da51f78963e12a57c904e02183253
|
4
|
+
data.tar.gz: 36e10a49ccac0e160564144a0c55bdfbef240a97
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f7099cd0cba999e8244ae605f1867e507601f4650129e79d1d3325e2a77f13049c752a07b8938ba335241dbec366b71b6d312a50de42a9cb0113264ff67ea926
|
7
|
+
data.tar.gz: b10f257c96e7a39a9a91aa17375edd3e4ab610c35693d91848b6a2236aac2293ae2ab110cb54db9623e62bab6e8186fabeb99cc6255afd592be763106a7feddf
|
data/CHANGELOG.md
CHANGED
@@ -68,6 +68,12 @@ module Halite
|
|
68
68
|
# keys based on the class definition.
|
69
69
|
klass.instance_variable_set(:@halite_original_priority_keys, removed_keys)
|
70
70
|
end
|
71
|
+
# Remove from the global node map.
|
72
|
+
if defined?(Chef::Resource.node_map)
|
73
|
+
removed_keys = remove_from_node_map(Chef::Resource.node_map, klass)
|
74
|
+
# Used down in patch_node_map.
|
75
|
+
klass.instance_variable_set(:@halite_original_nodemap_keys, removed_keys)
|
76
|
+
end
|
71
77
|
end
|
72
78
|
|
73
79
|
# Patch an object in to a global namespace for the duration of a block.
|
@@ -125,7 +131,10 @@ module Halite
|
|
125
131
|
return block.call unless defined?(klass.node_map)
|
126
132
|
begin
|
127
133
|
# Technically this is set to true on >=12.4, but this should work.
|
128
|
-
klass.
|
134
|
+
keys = klass.instance_variable_get(:@halite_original_nodemap_keys) | [name.to_sym]
|
135
|
+
keys.each do |key|
|
136
|
+
klass.node_map.set(key, klass)
|
137
|
+
end
|
129
138
|
block.call
|
130
139
|
ensure
|
131
140
|
remove_from_node_map(klass.node_map, klass)
|
data/lib/halite/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: halite
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Noah Kantrowitz
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-06-
|
11
|
+
date: 2015-06-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: chef
|