herokuconf 0.0.6 → 0.0.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/herokuconf.gemspec +1 -1
- data/lib/herokuconf.rb +6 -2
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: df66d31b1b270fa89cd82111bbbfd53edcf5db26
|
4
|
+
data.tar.gz: 7b6573bcc5afa806718c849e9b5e9200515bb2d3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e9ba1e06e911c0d318651787cba73fbfc36a36264182d31b861a142cb73e636e321565d13ba47c9f47260528f0413c811a28217c12041c09fcb4456426df1528
|
7
|
+
data.tar.gz: 90b61ea3b5c4714b403983432ddb42495511bc57973c7053281fa8c39edba7e414dd21ca8b0da3fea5aa5bfd18cf9ffaf8b95c7a86bc535a7b5b9aad46cea4c7
|
data/herokuconf.gemspec
CHANGED
data/lib/herokuconf.rb
CHANGED
@@ -7,14 +7,18 @@ module HerokuConf
|
|
7
7
|
class << self
|
8
8
|
DEFAULT_OPTIONS = {
|
9
9
|
app: nil,
|
10
|
-
keys: nil
|
10
|
+
keys: nil,
|
11
|
+
exclude: ['RACK_ENV']
|
11
12
|
}
|
12
13
|
|
13
14
|
def configure!(params = {})
|
14
15
|
return if ENV['DYNO']
|
15
|
-
app, keys = DEFAULT_OPTIONS.dup.merge!(params).values_at(
|
16
|
+
app, keys, exclude = DEFAULT_OPTIONS.dup.merge!(params).values_at(
|
17
|
+
:app, :keys, exclude
|
18
|
+
)
|
16
19
|
pairs = config_vars(app)
|
17
20
|
pairs.select! { |k, _| keys.include? k } if keys
|
21
|
+
pairs.reject! { |k, _| exclude.include? k } if exclude
|
18
22
|
pairs.each { |k, v| ENV[k] = v }
|
19
23
|
end
|
20
24
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: herokuconf
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Les Aker
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-03-01 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: netrc
|