osx_provision 0.9.2 → 0.9.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +8 -8
- data/CHANGES +4 -0
- data/lib/osx_provision/generic_provision.rb +25 -2
- data/lib/osx_provision/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
MjFhMWFkNDdlZWY1NGYyOThmNzQ1N2M3YTQzYzVjYmIyMjI5OTUyMQ==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
ZTU1NGY0YThjMGM3YTYwZWM3ZmVkM2ZkYzVlNjJhNWY3NWRkMzU4NA==
|
7
7
|
SHA512:
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
MWQ0MmNjZTU3ZWJjYmJiMTVjY2VmNWQ4MzFhMDM4MDJlYjg3YTQxN2JhYzQ4
|
10
|
+
ZWU4M2QwZTdiZDRjM2VkOWMyMjVlN2I5YmNkYmM3Yzc3YzdkOGU2ODY2NDg1
|
11
|
+
OTljNmVmYzM1MjA2MGNmMjIyN2RmMGM5NDgyOWY1ZWJmMjQ0OTQ=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
MWM5NjY0MTFjN2YxOGVjMTUzOTVmZjkzMmU2YTRmYWQ4NjlhNmVkZTNjMDAy
|
14
|
+
Y2IxZjY2Y2E5MjQ3ZmQ2NjIwODg5Y2MxZWQ3ZWM2NWE3OGJmNGY1Nzg5ODAx
|
15
|
+
MzBlNzE0YjA5MWZlYzA4NjE3NmQzM2QxMTNlMzhlOTYwZDgxODQ=
|
data/CHANGES
CHANGED
@@ -10,16 +10,39 @@ class GenericProvision
|
|
10
10
|
|
11
11
|
attr_reader :interpolator, :env, :script_list, :server_info
|
12
12
|
|
13
|
-
def initialize config_file_name,
|
13
|
+
def initialize config_file_name, scripts_file_names
|
14
14
|
@interpolator = TextInterpolator.new
|
15
15
|
|
16
16
|
@env = read_config(config_file_name)
|
17
17
|
|
18
|
-
@script_list =
|
18
|
+
@script_list = {}
|
19
|
+
|
20
|
+
scripts_file_names.each do |name|
|
21
|
+
@script_list.merge!(scripts(name))
|
22
|
+
end
|
23
|
+
|
24
|
+
# create_script_methods parent, self
|
19
25
|
|
20
26
|
@server_info = env[:node] ? env[:node] : {}
|
21
27
|
end
|
22
28
|
|
29
|
+
# def create_script_methods parent, current
|
30
|
+
# parent_metaclass = parent.singleton_class
|
31
|
+
# current_metaclass = current.singleton_class
|
32
|
+
#
|
33
|
+
# current.script_list.keys.each do |name|
|
34
|
+
# # create methods on parent, e.g. thor or rake file
|
35
|
+
# parent_metaclass.send(:define_method, name.to_sym) do |*args, &block|
|
36
|
+
# current.send(name, args, block)
|
37
|
+
# end
|
38
|
+
#
|
39
|
+
# # create methods on installer
|
40
|
+
# current_metaclass.send(:define_method, name.to_sym) do |_, _|
|
41
|
+
# current.send :run, current.server_info, name.to_s, current.env
|
42
|
+
# end
|
43
|
+
# end
|
44
|
+
# end
|
45
|
+
|
23
46
|
protected
|
24
47
|
|
25
48
|
def read_config config_file_name
|