ridgepole 0.3.9 → 0.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/ridgepole/dsl_parser.rb +9 -3
- data/lib/ridgepole/version.rb +1 -1
- data/ridgepole.gemspec +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7284de718aedfc85207971f129586dffa5fd49a7
|
4
|
+
data.tar.gz: 2db55a88104e340788971af634b202ebf80a93db
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ed41b7613dcd5e5a87b3673a27bffbad4043638203af53941d1798b77841a639cdb3d696ffff77bfed52d3bf3b8eebe0344f426d759eed4cb40e6ee108ddb46e
|
7
|
+
data.tar.gz: 875a498eba1c73fa5898d1522106bcddc4bf22045198823b9e1d486242cb33b607d0b901ae7ca02e51444e64cf3ce01983fdabe3f25645f496c726a134fad241
|
data/lib/ridgepole/dsl_parser.rb
CHANGED
@@ -46,7 +46,13 @@ class Ridgepole::DSLParser
|
|
46
46
|
|
47
47
|
def self.eval(dsl, opts = {})
|
48
48
|
ctx = self.new(opts)
|
49
|
-
|
49
|
+
|
50
|
+
if opts[:path]
|
51
|
+
ctx.instance_eval(dsl, opts[:path])
|
52
|
+
else
|
53
|
+
ctx.instance_eval(dsl)
|
54
|
+
end
|
55
|
+
|
50
56
|
ctx.__definition
|
51
57
|
end
|
52
58
|
|
@@ -83,9 +89,9 @@ class Ridgepole::DSLParser
|
|
83
89
|
schemafile = File.join(@__working_dir, file)
|
84
90
|
|
85
91
|
if File.exist?(schemafile)
|
86
|
-
instance_eval(File.read(schemafile))
|
92
|
+
instance_eval(File.read(schemafile), schemafile)
|
87
93
|
elsif File.exist?(schemafile + '.rb')
|
88
|
-
instance_eval(File.read(schemafile + '.rb'))
|
94
|
+
instance_eval(File.read(schemafile + '.rb'), schemafile + '.rb')
|
89
95
|
else
|
90
96
|
Kernel.require(file)
|
91
97
|
end
|
data/lib/ridgepole/version.rb
CHANGED
data/ridgepole.gemspec
CHANGED
@@ -19,7 +19,7 @@ Gem::Specification.new do |spec|
|
|
19
19
|
spec.require_paths = ['lib']
|
20
20
|
|
21
21
|
spec.add_dependency 'activerecord'
|
22
|
-
spec.add_dependency 'activerecord-mysql-unsigned', '
|
22
|
+
spec.add_dependency 'activerecord-mysql-unsigned', '~> 0.1.3'
|
23
23
|
spec.add_development_dependency 'bundler'
|
24
24
|
spec.add_development_dependency 'rake'
|
25
25
|
spec.add_development_dependency 'rspec', '>= 3.0.0'
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ridgepole
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Genki Sugawara
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-08-
|
11
|
+
date: 2014-08-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activerecord
|
@@ -28,14 +28,14 @@ dependencies:
|
|
28
28
|
name: activerecord-mysql-unsigned
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- -
|
31
|
+
- - ~>
|
32
32
|
- !ruby/object:Gem::Version
|
33
33
|
version: 0.1.3
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
|
-
- -
|
38
|
+
- - ~>
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: 0.1.3
|
41
41
|
- !ruby/object:Gem::Dependency
|