wraithdb 0.0.6 → 0.0.7
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/wraithdb/schema.rb +6 -1
- data/lib/wraithdb/version.rb +1 -1
- metadata +2 -2
data/lib/wraithdb/schema.rb
CHANGED
@@ -34,7 +34,12 @@ module WraithDB
|
|
34
34
|
def load
|
35
35
|
return if @loaded
|
36
36
|
@loaded = true
|
37
|
-
|
37
|
+
schema_locations = [
|
38
|
+
ENV["SCHEMA"],
|
39
|
+
"#{Rails.root}/db/#{Rails.env}_schema.rb",
|
40
|
+
"#{Rails.root}/db/schema.rb"
|
41
|
+
]
|
42
|
+
file = schema_locations.find { |f| f.present? && File.exist?(f) }
|
38
43
|
source = File.read(file)
|
39
44
|
if (source =~ SCHEMA_REGEX && source =~ END_REGEX)
|
40
45
|
source.sub!(SCHEMA_REGEX, "")
|
data/lib/wraithdb/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: wraithdb
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.7
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-
|
12
|
+
date: 2013-02-20 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: activerecord
|