roku_builder 4.6.0 → 4.6.1

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: 14a9f485846b42df5df6187aeeb2611620c90efa
4
- data.tar.gz: 52ccf4b5a9642cf40ec84552464ce03d542f7f17
3
+ metadata.gz: 6322e6c2a7bbfdd85a34a647b6f94bfafdf8ff57
4
+ data.tar.gz: 1e390ba875b1f1fddfbe9eb2b11baa6d8cadb082
5
5
  SHA512:
6
- metadata.gz: e0e3c653d5482fa18f1cf46d86fe8cd79a0f00db30c0317e886927027d6693a4f4292f7a9a66ddb2807ff9369d2e6bda1db0c17170e9060087df15ea48350d30
7
- data.tar.gz: f2207a16b2bc713971293de9e553f6dbd53375dbf83119c5d71d30cb36c3cd271bc39d3ce1ff7d2e6789f07ba6ea26920866bcab6c6f5d590e2a926739a0bf2a
6
+ metadata.gz: d1afd342f9649741f4ce8e423175a8dedba501410813181e98eb49bf6a1067853a44f8de0497000734cacbd57dfa344fad1d8a632246c7b207a48618ac7be28b
7
+ data.tar.gz: f0c1a0479f891055d7fd8ce52c553d3fed30301a98151d47ab40382981640f4cde545f6a953bdfe813b2147abf273d66aef88ef6e01e472d6809a65ab014a5b5
data/CHANGELOG CHANGED
@@ -1,4 +1,8 @@
1
- = 4.6.0
1
+ = 4.6.1 =
2
+
3
+ - Prevent double loading configs
4
+
5
+ = 4.6.0 =
2
6
 
3
7
  - Allow locally defined key files
4
8
  - Allow locally defined config to omit directory
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- roku_builder (4.6.0)
4
+ roku_builder (4.6.1)
5
5
  faraday (~> 0.13)
6
6
  faraday-digestauth (~> 0.2)
7
7
  git (~> 1.3)
@@ -135,4 +135,4 @@ DEPENDENCIES
135
135
  yard (~> 0.9)
136
136
 
137
137
  BUNDLED WITH
138
- 1.15.1
138
+ 1.16.1
@@ -82,9 +82,11 @@ module RokuBuilder
82
82
 
83
83
 
84
84
  def load_config
85
+ @loaded_configs = []
85
86
  @config = {parent_config: @options[:config]}
86
87
  depth = 1
87
88
  while @config[:parent_config]
89
+ @loaded_configs.push(File.expand_path(@config[:parent_config]))
88
90
  parent_config_hash = read_config(parent_io)
89
91
  @config[:child_config] = @config[:parent_config]
90
92
  @config.delete(:parent_config)
@@ -119,7 +121,7 @@ module RokuBuilder
119
121
 
120
122
  def merge_local_config
121
123
  local_config_path = "./.roku_config.json"
122
- if File.exist?(local_config_path)
124
+ if File.exist?(local_config_path) and !@loaded_configs.include?(File.expand_path(local_config_path))
123
125
  local_config_hash = read_config(File.open(local_config_path))
124
126
  add_missing_directories(local_config_hash)
125
127
  @config = @config.deep_merge(local_config_hash)
@@ -129,7 +131,7 @@ module RokuBuilder
129
131
  def add_missing_directories(local_config)
130
132
  if local_config[:projects]
131
133
  local_config[:projects].each_pair do |key,value|
132
- unless value[:directory]
134
+ unless !value.is_a?(Hash) or value[:directory]
133
135
  local_config[:projects][key][:directory] = RokuBuilder.system(command: "pwd")
134
136
  end
135
137
  end
@@ -2,5 +2,5 @@
2
2
 
3
3
  module RokuBuilder
4
4
  # Version of the RokuBuilder Gem
5
- VERSION = "4.6.0"
5
+ VERSION = "4.6.1"
6
6
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: roku_builder
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.6.0
4
+ version: 4.6.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - greeneca