meowth 0.0.1 → 0.0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/meowth/config.rb +2 -5
- data/lib/meowth/version.rb +1 -1
- 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: 45f481e5db1226716df53655c4140f3d72fd59f3
|
4
|
+
data.tar.gz: fd5e37a958f99126eb80641cecdb502b7c0f12f7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0b242fe93880d7b831764ecc10b3c6e3afb9829a7d4e742eaf59fe95c85f90ab847167272b615c8ca8106b61835c11e0a2844150f4ab12b50e1c4f01d3d57295
|
7
|
+
data.tar.gz: b8a04b0e60a1d28f419e08515fb1ff1854a3c34111ecbdde8844839d5755c83ac2e6ac43e97c2ff7d1868f4d4ae597f90d60a0d5f4926a6cda4275e7f86fdc10
|
data/lib/meowth/config.rb
CHANGED
@@ -60,16 +60,13 @@ module Meowth
|
|
60
60
|
def self.init_constant
|
61
61
|
if defined?(::Rails) and Rails.root
|
62
62
|
config_file = Rails.root.join('config/meowth.yml')
|
63
|
-
|
63
|
+
@config = YAML.load(ERB.new(File.read(config_file)).result)[Rails.env] if File.exist?(config_file)
|
64
64
|
else
|
65
65
|
require "yaml"
|
66
66
|
rails_config_file = File.join(Dir.getwd, 'config/meowth.yml')
|
67
67
|
if File.exist?(rails_config_file)
|
68
68
|
rails_env = ENV['RAILS_ENV'] || 'default'
|
69
|
-
config = YAML.load(ERB.new(File.read(rails_config_file)).result)[rails_env]
|
70
|
-
if config
|
71
|
-
@config = config
|
72
|
-
end
|
69
|
+
@config = YAML.load(ERB.new(File.read(rails_config_file)).result)[rails_env] if File.exist?(rails_config_file)
|
73
70
|
end
|
74
71
|
end
|
75
72
|
end
|
data/lib/meowth/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: meowth
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.1
|
4
|
+
version: 0.0.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jack Pan
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-03-
|
11
|
+
date: 2017-03-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|