cfn-flow 0.10.0 → 0.11.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: a758c3ab1d93215d5c19a055eee983c2f5776b2c
4
- data.tar.gz: 1b83fda8361c92793ef426042e6aafb13c3e6ebf
3
+ metadata.gz: b6cfb05fe9483b53ebf2e91837f2308da5436999
4
+ data.tar.gz: 301115c13627dcc7761e4b0ad991ddc9b7eaf896
5
5
  SHA512:
6
- metadata.gz: 50dee4788230e13a9af86471b9c7ac3fcb1df86b136bc29d7462ddcbb76a85a218edb1514d4c590311ea204d43dbe8ee1f2002668236f46e59215346dd4707de
7
- data.tar.gz: 7ac38fd70956fbbd4409d0abfbfc452ec5e565605812def986e956edce459c3ba513e9c8928054ba7a4a95f12601864273dbfd69366af759d447e524929db202
6
+ metadata.gz: eda2f68c192c4f6c7c6a1d80bf921dec04c542f8c378e679b69d3ed979629393af3de32388f2111de48a35aae1dc26b5604476e3f7c66fe76827b01831df773e
7
+ data.tar.gz: dd4c3ac891455ab3324b2d481964d6e3e1687ef315b25d583a323e047250c8d7b1e8f0236af053a74b9c1e3ec9a95c6c118b68d3cceddf1b7447c04e66b5883a
data/README.md CHANGED
@@ -401,7 +401,7 @@ Publish templates to S3 with immutable release names, or overwrite "dev names"
401
401
  for quicker testing.
402
402
 
403
403
  **Note:** Publishing to S3 is only needed if you want to use [nested stack resources](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-stack.html),
404
- (that is, stacks that lainclude other stacks).
404
+ (that is, stacks that include other stacks).
405
405
 
406
406
  ```
407
407
  # For example:
data/Rakefile CHANGED
@@ -1,5 +1,3 @@
1
- require "rubygems"
2
- require "bundler/setup"
3
1
  require "bundler/gem_tasks"
4
2
  require 'rake/testtask'
5
3
 
data/bin/_guard-core ADDED
@@ -0,0 +1,16 @@
1
+ #!/usr/bin/env ruby
2
+ #
3
+ # This file was generated by Bundler.
4
+ #
5
+ # The application '_guard-core' is installed as part of a gem, and
6
+ # this file is here to facilitate running it.
7
+ #
8
+
9
+ require "pathname"
10
+ ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
11
+ Pathname.new(__FILE__).realpath)
12
+
13
+ require "rubygems"
14
+ require "bundler/setup"
15
+
16
+ load Gem.bin_path("guard", "_guard-core")
data/bin/guard ADDED
@@ -0,0 +1,16 @@
1
+ #!/usr/bin/env ruby
2
+ #
3
+ # This file was generated by Bundler.
4
+ #
5
+ # The application 'guard' is installed as part of a gem, and
6
+ # this file is here to facilitate running it.
7
+ #
8
+
9
+ require "pathname"
10
+ ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
11
+ Pathname.new(__FILE__).realpath)
12
+
13
+ require "rubygems"
14
+ require "bundler/setup"
15
+
16
+ load Gem.bin_path("guard", "guard")
@@ -49,9 +49,10 @@ module CfnFlow
49
49
  end
50
50
 
51
51
  def local_data
52
+ data = ERB.new(File.read(local_path)).result(binding)
52
53
  # We *could* load JSON as YAML, but that would generate confusing errors
53
54
  # in the case of a JSON syntax error.
54
- @local_data ||= yaml? ? YAML.load_file(local_path) : MultiJson.load(File.read(local_path))
55
+ @local_data ||= yaml? ? YAML.load(data) : MultiJson.load(data)
55
56
  rescue Exception => error
56
57
  # Tag & re-raise any error
57
58
  error.extend(CfnFlow::Template::Error)
@@ -1,3 +1,3 @@
1
1
  module CfnFlow
2
- VERSION = '0.10.0'
2
+ VERSION = '0.11.0'
3
3
  end
@@ -110,6 +110,10 @@ describe 'CfnFlow::Template' do
110
110
  template.local_data.must_be_kind_of Hash
111
111
  end
112
112
 
113
+ it 'should parse ERB' do
114
+ CfnFlow::Template.new('spec/data/erb-test.yml').local_data.must_equal({'foo' => 3})
115
+ end
116
+
113
117
  it 'should raise an error on invalid json data' do
114
118
  -> { CfnFlow::Template.new('spec/data/invalid.json').local_data }.must_raise CfnFlow::Template::Error
115
119
  end
@@ -0,0 +1,2 @@
1
+ ---
2
+ foo: <%= 1+2 %>
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cfn-flow
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.10.0
4
+ version: 0.11.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Aaron Suggs
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-12-01 00:00:00.000000000 Z
11
+ date: 2016-04-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk
@@ -89,7 +89,9 @@ extra_rdoc_files: []
89
89
  files:
90
90
  - README.md
91
91
  - Rakefile
92
+ - bin/_guard-core
92
93
  - bin/cfn-flow
94
+ - bin/guard
93
95
  - bin/rake
94
96
  - lib/cfn-flow.rb
95
97
  - lib/cfn_flow.rb
@@ -107,6 +109,7 @@ files:
107
109
  - spec/cfn_flow/template_spec.rb
108
110
  - spec/cfn_flow_spec.rb
109
111
  - spec/data/cfn-flow.yml
112
+ - spec/data/erb-test.yml
110
113
  - spec/data/invalid.json
111
114
  - spec/data/invalid.yml
112
115
  - spec/data/sqs.template
@@ -125,7 +128,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
125
128
  requirements:
126
129
  - - ">="
127
130
  - !ruby/object:Gem::Version
128
- version: 2.1.0
131
+ version: 2.2.0
129
132
  required_rubygems_version: !ruby/object:Gem::Requirement
130
133
  requirements:
131
134
  - - ">="
@@ -133,7 +136,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
133
136
  version: '0'
134
137
  requirements: []
135
138
  rubyforge_project:
136
- rubygems_version: 2.4.5.1
139
+ rubygems_version: 2.5.2
137
140
  signing_key:
138
141
  specification_version: 4
139
142
  summary: A CLI for CloudFormation templates
@@ -145,6 +148,7 @@ test_files:
145
148
  - spec/cfn_flow/template_spec.rb
146
149
  - spec/cfn_flow_spec.rb
147
150
  - spec/data/cfn-flow.yml
151
+ - spec/data/erb-test.yml
148
152
  - spec/data/invalid.json
149
153
  - spec/data/invalid.yml
150
154
  - spec/data/sqs.template