sparkle_formation 3.0.36 → 3.0.38

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: 354d57e9781c395c6cecaedf6e80e602db3d29afc063dcd240bb82a19a9b6e13
4
- data.tar.gz: 4b34ece3ddb9f5514d0a59ea4bfe74f8fe4dd9e763dd082b95b996283ef95a8a
3
+ metadata.gz: 50546ecd070328989d5938eeb94e73740158ccca0696f9ad774c3313bc747190
4
+ data.tar.gz: 86e63295a0ec22cea46785c60c0fbb2e07c55602ea442e67288f9513ccf0b6e8
5
5
  SHA512:
6
- metadata.gz: cda465c5335a6092926f91b069b0e1745e76b54e59ea1786747e408e7b185304540a69a132eaaccb8482e54f37a4e70eeeb7258823f67b87427b579823b0c8ea
7
- data.tar.gz: 628a65f847c332c73ee6bb8c4658901552adf6a94b60c49cb4dd1e1ac880c6904d0f7f80c704fe7b1fc7131e299c3d93018cd649f1b89082eb3239c444297b94
6
+ metadata.gz: fec18b30a1357b633a243967e3cf8177c739886d22be4ca1e1dbc3bd84a8e812e8d9af9b7a68878ebe8ee69e35bbd15037619032b47f3f6da74d2b99eb254bab
7
+ data.tar.gz: f2683788101c688649bed5178e939dd0372edaa5972c3616478a812585ae8471abfe3f69af3cb876061173f6f3bb7f9971b378c2763e97866fb948befc0795e3
@@ -1,3 +1,6 @@
1
+ # v3.0.38
2
+ * Fix root template audit log setup
3
+
1
4
  # v3.0.36
2
5
  * Add audit log feature to record template construction
3
6
 
@@ -49,4 +49,7 @@ File.open('doc/UserDocs/index.html', 'w') do |file|
49
49
  file.puts '<html><head><meta http-equiv="refresh" content="0; url=README.html" /></head></html>'
50
50
  end
51
51
 
52
+ FileUtils.mkdir_p('doc/img')
53
+ FileUtils.cp('img/sparkle-formation.png', 'doc/img/')
54
+
52
55
  puts 'done.'
@@ -112,7 +112,7 @@ class SparkleFormation
112
112
  #
113
113
  # @param output_name [String] name of output
114
114
  # @param outputs [Hash] listing of outputs
115
- # @reutrn [Hash] reference to output value (used for setting parameter)
115
+ # @return [Hash] reference to output value (used for setting parameter)
116
116
  def make_output_available(output_name, outputs)
117
117
  bubble_path = outputs[output_name].root_path - root_path
118
118
  drip_path = root_path - outputs[output_name].root_path
@@ -92,7 +92,7 @@ class SparkleFormation
92
92
  #
93
93
  # @param output_name [String] name of output
94
94
  # @param outputs [Hash] listing of outputs
95
- # @reutrn [Hash] reference to output value (used for setting parameter)
95
+ # @return [Hash] reference to output value (used for setting parameter)
96
96
  def make_output_available(output_name, outputs)
97
97
  bubble_path = outputs[output_name].root_path - root_path
98
98
  drip_path = root_path - outputs[output_name].root_path
@@ -156,7 +156,7 @@ class SparkleFormation
156
156
  # @param output_name [String] name of output
157
157
  # @param outputs [Hash] listing of outputs
158
158
  # @param source_stack [SparkleFormation] requesting stack
159
- # @reutrn [Hash] reference to output value (used for setting parameter)
159
+ # @return [Hash] reference to output value (used for setting parameter)
160
160
  def make_output_available(output_name, outputs, source_stack)
161
161
  bubble_path = outputs[output_name].root_path - root_path
162
162
  drip_path = root_path - outputs[output_name].root_path
@@ -76,7 +76,7 @@ class SparkleFormation
76
76
  #
77
77
  # @param output_name [String] name of output
78
78
  # @param outputs [Hash] listing of outputs
79
- # @reutrn [Hash] reference to output value (used for setting parameter)
79
+ # @return [Hash] reference to output value (used for setting parameter)
80
80
  def make_output_available(output_name, outputs)
81
81
  bubble_path = outputs[output_name].root_path - root_path
82
82
  drip_path = root_path - outputs[output_name].root_path
@@ -111,7 +111,7 @@ class SparkleFormation
111
111
  # @param output_name [String] name of output
112
112
  # @param outputs [Hash] listing of outputs
113
113
  # @param source_stack [SparkleFormation] requesting stack
114
- # @reutrn [Hash] reference to output value (used for setting parameter)
114
+ # @return [Hash] reference to output value (used for setting parameter)
115
115
  def make_output_available(output_name, outputs, source_stack)
116
116
  bubble_path = outputs[output_name].root_path - root_path
117
117
  drip_path = root_path - outputs[output_name].root_path
@@ -287,7 +287,7 @@ class SparkleFormation
287
287
  # @param name [String, Symbol] name of item
288
288
  # @param target_provider [String, Symbol] restrict to provider
289
289
  # @return [Smash] requested item
290
- # @raises [NameError, Error::NotFound]
290
+ # @raise [NameError, Error::NotFound]
291
291
  def get(type, name, target_provider = nil)
292
292
  unless TYPES.keys.include?(type.to_s)
293
293
  raise NameError.new "Invalid type requested (#{type})! Valid types: #{TYPES.keys.join(", ")}"
@@ -94,7 +94,7 @@ class SparkleFormation
94
94
  # @param options [Hash]
95
95
  # @option options [String, Symbol] :provider override provider restriction when fetching dynamic
96
96
  # @note All options are passed to dynamic with custom_name
97
- # @yieldblock [new_struct] Provides newly inserted structure
97
+ # @yield [new_struct] Provides newly inserted structure
98
98
  # @yieldparam new_struct [SparkleStruct] newly inserted structure which can be modified
99
99
  # @yieldreturn [Object] discarded
100
100
  # @return [self]
@@ -132,7 +132,7 @@ class SparkleFormation
132
132
  # @option options [Truthy, Falsey] :overwrite_name when set to true, will not include
133
133
  # template name in resource name
134
134
  # @option options [Hash] :parameters compile time parameter values to pass to nested template
135
- # @yieldblock [new_struct] Provides newly inserted structure
135
+ # @yield [new_struct] Provides newly inserted structure
136
136
  # @yieldparam new_struct [SparkleStruct] newly inserted structure which can be modified
137
137
  # @yieldreturn [Object] discarded
138
138
  # @return [self]
@@ -392,7 +392,7 @@ class SparkleFormation
392
392
  # Reference output value from nested stack
393
393
  #
394
394
  # @param stack_name [String, Symbol] logical resource name of stack
395
- # @apram output_name [String, Symbol] stack output name
395
+ # @param output_name [String, Symbol] stack output name
396
396
  def _cf_stack_output(stack_name, output_name)
397
397
  _cf_attr(_process_key(stack_name), "Outputs.#{__attribute_key(output_name)}")
398
398
  end
@@ -152,7 +152,7 @@ class SparkleFormation
152
152
  # @param name [String, Symbol] name of item
153
153
  # @param target_provider [String, Symbol] restrict to provider
154
154
  # @return [Smash] requested item
155
- # @raises [NameError, Error::NotFound]
155
+ # @raise [NameError, Error::NotFound]
156
156
  def get(type, name, target_provider = nil)
157
157
  type_name = Sparkle::TYPES[type.to_s]
158
158
  unless type_name
@@ -722,7 +722,7 @@ class SparkleFormation
722
722
  #
723
723
  # @param params [Hash] parameter set
724
724
  # @return [Hash] parameter set
725
- # @raises [ArgumentError]
725
+ # @raise [ArgumentError]
726
726
  def set_generation_parameters!(params)
727
727
  params.each do |name, value|
728
728
  unless value.is_a?(Hash)
@@ -817,12 +817,22 @@ class SparkleFormation
817
817
  when Composition::Component
818
818
  if item.block
819
819
  if item.key == "__base__"
820
- record = audit_log.push(
821
- type: :template,
822
- name: name,
823
- location: item.block.source_location.first,
824
- caller: [:template, 0],
825
- ) if parent.nil?
820
+ if parent.nil?
821
+ record = audit_log.push(
822
+ type: :template,
823
+ name: name,
824
+ location: item.block.source_location.first,
825
+ caller: [:template, 0],
826
+ )
827
+ # NOTE: Move audit log records under new record's
828
+ # audit log. This allows components to be listed
829
+ # logically under the template record instead of
830
+ # at the same level.
831
+ record.audit_log.list.replace(audit_log.list)
832
+ record.audit_log.list.delete(record)
833
+ audit_log.list.clear
834
+ audit_log.list << record
835
+ end
826
836
  else
827
837
  record = audit_log.push(
828
838
  type: :component,
@@ -1004,7 +1014,7 @@ class SparkleFormation
1004
1014
  #
1005
1015
  # @param output_name [String] name of output
1006
1016
  # @param outputs [Hash] listing of outputs
1007
- # @reutrn [Hash] reference to output value (used for setting parameter)
1017
+ # @return [Hash] reference to output value (used for setting parameter)
1008
1018
  def make_output_available(output_name, outputs)
1009
1019
  {}
1010
1020
  end
@@ -170,7 +170,7 @@ class SparkleFormation
170
170
  #
171
171
  # @param arg [String, Symbol] name of parameter
172
172
  # @return [Object]
173
- # @raises [ArgumentError]
173
+ # @raise [ArgumentError]
174
174
  def _state(arg)
175
175
  result = super
176
176
  if @self && result.nil?
@@ -11,7 +11,7 @@ class SparkleFormation
11
11
  # @param val [Object] value
12
12
  # @param types [Class, Array<Class>] valid types
13
13
  # @return [NilClass]
14
- # @raises [TypeError]
14
+ # @raise [TypeError]
15
15
  def __t_check(val, types)
16
16
  types = [types] unless types.is_a?(Array)
17
17
  if types.none? { |t| val.is_a?(t) }
@@ -28,7 +28,7 @@ class SparkleFormation
28
28
  # Validate given value is String or Symbol type
29
29
  #
30
30
  # @return [NilClass]
31
- # @raises [TypeError]
31
+ # @raise [TypeError]
32
32
  def __t_stringish(val)
33
33
  __t_check(val, [String, Symbol])
34
34
  end
@@ -36,7 +36,7 @@ class SparkleFormation
36
36
  # Validate given value is a Hash type
37
37
  #
38
38
  # @return [NilClass]
39
- # @raises [TypeError]
39
+ # @raise [TypeError]
40
40
  def __t_hashish(val)
41
41
  __t_check(val, Hash)
42
42
  end
@@ -1,5 +1,5 @@
1
1
  # Unicorns and rainbows
2
2
  class SparkleFormation
3
3
  # Current library version
4
- VERSION = Gem::Version.new("3.0.36")
4
+ VERSION = Gem::Version.new("3.0.38")
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sparkle_formation
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.36
4
+ version: 3.0.38
5
5
  platform: ruby
6
6
  authors:
7
7
  - Chris Roberts
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-01-23 00:00:00.000000000 Z
11
+ date: 2019-01-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: attribute_struct
@@ -341,8 +341,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
341
341
  - !ruby/object:Gem::Version
342
342
  version: '0'
343
343
  requirements: []
344
- rubyforge_project:
345
- rubygems_version: 2.7.6
344
+ rubygems_version: 3.0.1
346
345
  signing_key:
347
346
  specification_version: 4
348
347
  summary: Orchestration Template Generator