env_enforcer 0.0.0 → 0.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/env_enforcer.gemspec +2 -2
- data/lib/env_enforcer.rb +5 -0
- data/lib/env_enforcer/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 892660e190d489aa9654acdee9c44e3cbb734ff0
|
4
|
+
data.tar.gz: 10e7c0e516106dc4e1d7a7525722363fb12a9792
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2cb241c225a0d58bee49a75f4a3b9508fa57f8cf760703a825f32550d812bf231dd06c665c05c53804ceb192f95fb1ef9b909e4828ea37039e9f0c0b8894c841
|
7
|
+
data.tar.gz: 8d657a4368615dbc5dac5221e371f51141153ec83211f0141c9e5a2fe933c1c74adfb1946148b85b7c7f408f9ba35a0e85839af2b38947ed8f9ae2b50b5bd443
|
data/env_enforcer.gemspec
CHANGED
@@ -7,11 +7,11 @@ Gem::Specification.new do |spec|
|
|
7
7
|
spec.name = "env_enforcer"
|
8
8
|
spec.version = EnvEnforcer::VERSION
|
9
9
|
spec.authors = ["Adam Steel", "Joel Hawksley"]
|
10
|
-
spec.email = ["adamgsteel@gmail.com", "joel@
|
10
|
+
spec.email = ["adamgsteel@gmail.com", "joel@mojotech.com"]
|
11
11
|
|
12
12
|
spec.summary = %q{Enforce ENV key definition in your apps.}
|
13
13
|
spec.description = %q{env-enforcer allows you to list your required ENV variables, and checks for their presence at deploy time.}
|
14
|
-
spec.homepage = "https://github.com/mojotech/env-enforcer"
|
14
|
+
spec.homepage = "https://www.github.com/mojotech/env-enforcer"
|
15
15
|
|
16
16
|
# Prevent pushing this gem to RubyGems.org by setting 'allowed_push_host', or
|
17
17
|
# delete this section to allow pushing this gem to any host.
|
data/lib/env_enforcer.rb
CHANGED
@@ -7,6 +7,7 @@ class MissingEnvKey < StandardError; end
|
|
7
7
|
module EnvEnforcer
|
8
8
|
class << self
|
9
9
|
def call
|
10
|
+
# handle missing config file
|
10
11
|
raise MissingEnvKey, error_message if missing_keys.size > 0
|
11
12
|
end
|
12
13
|
|
@@ -38,4 +39,8 @@ module EnvEnforcer
|
|
38
39
|
missing_keys = (required_keys - defined_keys)
|
39
40
|
end
|
40
41
|
end
|
42
|
+
|
43
|
+
class Railtie < ::Rails::Railtie
|
44
|
+
config.after_initialize { EnvEnforcer.call }
|
45
|
+
end
|
41
46
|
end
|
data/lib/env_enforcer/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: env_enforcer
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Adam Steel
|
@@ -71,7 +71,7 @@ description: env-enforcer allows you to list your required ENV variables, and ch
|
|
71
71
|
for their presence at deploy time.
|
72
72
|
email:
|
73
73
|
- adamgsteel@gmail.com
|
74
|
-
- joel@
|
74
|
+
- joel@mojotech.com
|
75
75
|
executables: []
|
76
76
|
extensions: []
|
77
77
|
extra_rdoc_files: []
|
@@ -87,7 +87,7 @@ files:
|
|
87
87
|
- env_enforcer.gemspec
|
88
88
|
- lib/env_enforcer.rb
|
89
89
|
- lib/env_enforcer/version.rb
|
90
|
-
homepage: https://github.com/mojotech/env-enforcer
|
90
|
+
homepage: https://www.github.com/mojotech/env-enforcer
|
91
91
|
licenses: []
|
92
92
|
metadata: {}
|
93
93
|
post_install_message:
|