datafile 0.2.4 → 0.2.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/datafile/builder.rb +14 -0
- data/lib/datafile/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: cf81810d2af02c7ccd64d4e103dc912737d1d585
|
4
|
+
data.tar.gz: 7d1b6dac27a44fce550bd203ed76cb6a6df1e32d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e43a593bc7dfebf016aff5c382f3032664988c672a7950d887dc4f901998754e1a384aa41d86e2d88b0cdc63caed1f957d59f6aafefa92659ab15f91028e8a61
|
7
|
+
data.tar.gz: bd225c4c8daa8261151e0568a77b3930fc9335089d22b0bd1d1325cbcfcadf8bb535d617768c933f58165cabd69524b0462e61db0a14282667eed7442c348ebb
|
data/lib/datafile/builder.rb
CHANGED
@@ -18,6 +18,20 @@ class Builder ## "simple" builder (one file, one datafile)
|
|
18
18
|
|
19
19
|
include LogUtils::Logging
|
20
20
|
|
21
|
+
## add models shortcuts/constants if exist
|
22
|
+
## todo/check: is there a better way ?
|
23
|
+
## e.g. just include in inline section/block - for example?
|
24
|
+
## check if already included? and check on load to include?
|
25
|
+
## models might not yet be required
|
26
|
+
|
27
|
+
if defined?( WorldDb ) && defined?( WorldDb::Models )
|
28
|
+
include WorldDb::Models
|
29
|
+
else
|
30
|
+
puts "*** sorry; can't include WorldDb::Models; not yet defined (required)"
|
31
|
+
end
|
32
|
+
## todo/check: also include FootballDb::Models and BeerDb::Models ???
|
33
|
+
|
34
|
+
|
21
35
|
def initialize
|
22
36
|
@datafile = Datafile.new
|
23
37
|
end
|
data/lib/datafile/version.rb
CHANGED