minfra-cli 1.5.0 → 1.5.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
  SHA256:
3
- metadata.gz: 0d8c4fc413b6865291c1f47e12581c0f11131008f4852742969fb49a8be4272d
4
- data.tar.gz: 7e1eb348156ba8adb74bf7f5bb5055853c31a3c2802fa77497c7a529573f9d23
3
+ metadata.gz: 4e01ddd1aab00b59e77cca198cb41188270b77202f900afef2ea693029cc25bf
4
+ data.tar.gz: 44e3c6eb7d60db3a8cd3d55bb60793117bed96e0cc4b07c664275fc71bf38b49
5
5
  SHA512:
6
- metadata.gz: efa9ca0853ee602c708770a42cd6c1269f996dbcb70d4170cb630b815df161bc280bd5afb1ce608a4afefa699a6df78fa22c099260bfe3853ce4da7b8a601745
7
- data.tar.gz: 28e53a02daacbe1c3ccc33fa2e273a52ac04c7b9189c559a93b7d4fd5840bae0eb837ebbee16e74df533dd574b84eb350805ffca22bad2e4da09b209af7d916a
6
+ metadata.gz: 9d76c1b520371c53b90988283a19979f773ad955520ba82a7500de27918f6b52744c091305422a66ea96a982dd21052738344b799b300604b04bd52b2302a5dd
7
+ data.tar.gz: 437a304792db570235878164058a6cd12433d75e644ddec7f058fe5154bf9b955bf9613113d354e21b445a1bc96966b547f58ca7556d6ee0ba19154893905730
data/CHANGELOG.md CHANGED
@@ -1,3 +1,5 @@
1
+ # 1.5.1
2
+ * fixing hiera lookup caching error
1
3
  # 1.5.0
2
4
  * minfra project branch create now supports --prefix, keeps '-' (dash intact) and is config file configurable
3
5
  * Minfra::Cli::Config deep merges personal config (again)
@@ -1,5 +1,5 @@
1
1
  module Minfra
2
2
  module Cli
3
- VERSION = '1.5.0'.freeze
3
+ VERSION = '1.5.1'.freeze
4
4
  end
5
5
  end
data/lib/minfra/cli.rb CHANGED
@@ -90,15 +90,15 @@ module Minfra
90
90
  return cache[value] if cache.has_key?(value)
91
91
 
92
92
  values=value.split(".")
93
- value=values.shift
93
+ fst_value=values.shift
94
94
 
95
- if special_lookups[value]
96
- lookup_type={ merge_behavior: special_lookups[value]["merge"].to_sym }
95
+ if special_lookups[fst_value]
96
+ lookup_type={ merge_behavior: special_lookups[fst_value]["merge"].to_sym }
97
97
  else
98
98
  lookup_type=:deep
99
99
  end
100
100
 
101
- result=hiera.lookup(value, default, scope, nil, lookup_type)
101
+ result=hiera.lookup(fst_value, default, scope, nil, lookup_type)
102
102
  if !values.empty? && result.kind_of?(Hash) # we return nil or the scalar value and only drill down on hashes
103
103
  result=result.dig(*values)
104
104
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: minfra-cli
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.0
4
+ version: 1.5.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Peter Schrammel