furikake 0.1.7 → 0.1.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/lib/furikake/report.rb +3 -2
- data/lib/furikake/resource.rb +4 -4
- data/lib/furikake/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b4e9ff346a0ba1c616e1bd95fe56daeff8e14993b1bfbac5a30afc948d30284b
|
4
|
+
data.tar.gz: af7c57a0eebe4239245fd95525d9e9077889d50460fe6d95cb136ce183339403
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4ab877f29e6fe9f6cfab8f84f19ae7abe207b739027b439f70be29228e7452349f9de442c88fb0649948d60829c2d6fc57c05f577e40c940dd058395cbdb13f2
|
7
|
+
data.tar.gz: 394a286bc0c7b710ff48af5f1d8f5ede0f3ffb101a04134176dab1abeafae94dfba56e718114289c93e2c96fa8892db00e80463233eaa24e8bce3708bb29fd68
|
data/Gemfile.lock
CHANGED
data/lib/furikake/report.rb
CHANGED
@@ -7,7 +7,8 @@ module Furikake
|
|
7
7
|
def initialize(cli, params = nil)
|
8
8
|
$stdout.sync = true
|
9
9
|
@logger = Logger.new($stdout)
|
10
|
-
@
|
10
|
+
@cli = cli
|
11
|
+
@params = @cli ? read_furikake_yaml : params
|
11
12
|
raise ArgumentError, 'パラメータが設定されていません.' if @params.nil?
|
12
13
|
end
|
13
14
|
|
@@ -34,7 +35,7 @@ module Furikake
|
|
34
35
|
private
|
35
36
|
|
36
37
|
def generate(header, footer)
|
37
|
-
resource = Furikake::Resource.generate
|
38
|
+
resource = Furikake::Resource.generate(@cli, @params['resources'])
|
38
39
|
documents = <<"EOS"
|
39
40
|
#{header}
|
40
41
|
#{resource}
|
data/lib/furikake/resource.rb
CHANGED
@@ -1,8 +1,8 @@
|
|
1
1
|
module Furikake
|
2
2
|
class Resource
|
3
|
-
def self.generate
|
3
|
+
def self.generate(cli, resources)
|
4
4
|
documents = ''
|
5
|
-
load_resource_type.each do |type|
|
5
|
+
load_resource_type(cli, resources).each do |type|
|
6
6
|
if type.include?('addon')
|
7
7
|
$LOAD_PATH.push(Dir.pwd + '/addons')
|
8
8
|
require "#{type}"
|
@@ -26,9 +26,9 @@ module Furikake
|
|
26
26
|
documents
|
27
27
|
end
|
28
28
|
|
29
|
-
def self.load_resource_type
|
29
|
+
def self.load_resource_type(cli, resources)
|
30
30
|
type = []
|
31
|
-
config_defined_resources = load_config_resource_type
|
31
|
+
config_defined_resources = cli ? load_config_resource_type : resources['aws'].sort
|
32
32
|
default_resources = load_default_resource_type
|
33
33
|
if default_resources == config_defined_resources
|
34
34
|
type.push(default_resources)
|
data/lib/furikake/version.rb
CHANGED