simplygenius-atmos 0.11.9 → 0.11.10

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: 685baebb62604a3094114ff1616e1e044c0560ed9285c27686a4b8c3e635f964
4
- data.tar.gz: 2eadc8adc7ca8574de3d9f44d1af4d7668c17de8d9b6bee7f38c5f3234f47f63
3
+ metadata.gz: 53769d0519aa4f45feb52891aff6696ea1be0b054b0baf8d444799c1e93273de
4
+ data.tar.gz: a0a4726cf39261d4abc7d3880e06cc4b43d46dc6eeb0cedf53690d6aafb66f62
5
5
  SHA512:
6
- metadata.gz: 96249401ac017e427d0a5131f8ee441d51da30b91ae5da13a42bbddc258b1f7402c30411d5d304f2680c79e88d6e62eed8bfa26f0f70bd1b85eaf5ced69fd985
7
- data.tar.gz: 2025652bff07e78886a228f75e87183eb8b70ec0ec294223008f6abc4203ad9bf3cd617a39c06a521320812454c61e28d2a8c541eb9d5beb7c35b86bad4a3e3f
6
+ metadata.gz: 7fe49d0c4b8366d46f4ddd08fa3406759d43bfceed609ebe8f874e376d767e6bcb1855a97ea00dd99ca5ee082dc80edf38cd14fa87269de2814534677ec1644e
7
+ data.tar.gz: 3f5e5f627bb4f4f3ef5ed934bc3d0cb4675b189df6a060dbe43bb98d64c83d7987c278537d88f17a146ad61e94d18a0f9883957cd6ce4ba7faf6945c00860e33
data/CHANGELOG.md CHANGED
@@ -1,3 +1,8 @@
1
+ 0.11.10 (02/19/2020)
2
+ --------------------
3
+
4
+ * allow overriding atmos config from cli [f83902b](https://github.com/simplygenius/atmos/commit/f83902b)
5
+
1
6
  0.11.9 (02/13/2020)
2
7
  -------------------
3
8
 
@@ -51,6 +51,10 @@ module SimplyGenius
51
51
  "PATH", "adds additional paths to ruby load path",
52
52
  multivalued: true
53
53
 
54
+ option ["-o", "--override"],
55
+ "KEYVALUE", "overrides atmos configuration\nin the form 'some.config=value' where value can\nbe expressed in yaml form for complex types\ne.g. foo=1 foo=abc, foo=[x, y], foo={x: y}",
56
+ multivalued: true
57
+
54
58
  option ["-v", "--version"],
55
59
  :flag, "Shows the atmos version"
56
60
 
@@ -128,6 +132,13 @@ module SimplyGenius
128
132
 
129
133
  Logging.setup_logging(level, color?, log)
130
134
 
135
+ override_list.each do |o|
136
+ k, v = o.split("=")
137
+ v = YAML.load(v)
138
+ logger.debug("Overriding config '#{k}' = #{v.inspect}")
139
+ Atmos.config.[]=(k, v, additive: false)
140
+ end
141
+
131
142
  UI.color_enabled = color?
132
143
 
133
144
  Atmos.config.add_user_load_path(*load_path_list)
@@ -39,9 +39,9 @@ module SimplyGenius
39
39
  return result
40
40
  end
41
41
 
42
- def []=(key, value)
42
+ def []=(key, value, additive: true)
43
43
  load
44
- result = @config.notation_put(key, value)
44
+ result = @config.notation_put(key, value, additive: additive)
45
45
  return result
46
46
  end
47
47
 
@@ -1,5 +1,5 @@
1
1
  module SimplyGenius
2
2
  module Atmos
3
- VERSION = "0.11.9"
3
+ VERSION = "0.11.10"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: simplygenius-atmos
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.11.9
4
+ version: 0.11.10
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matt Conway
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2020-02-13 00:00:00.000000000 Z
11
+ date: 2020-02-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler