reality-generators 1.5.0 → 1.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/reality/generators/standard_artifact_dsl.rb +8 -5
- data/reality-generators.gemspec +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: af0b6c1e51e95d1a9cf3c1e2862eb73abe78c3c8
|
|
4
|
+
data.tar.gz: fc0000f5a449741e6e7e6dfc24780979eaab351a
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 2786178f4b984919e553adf443cca95d759c6057ddd7d503a789913d3f23fee55af10c2acce08039f380ed896ef45481b84c111d9d608c37e6184fc9ef773982
|
|
7
|
+
data.tar.gz: 7fbbf83ba65738e1ed2836465dfc9ba883d7c464215e7a2bb6ed62778e43e7b93ebf2d0657234382019806da1e04684315ee910709ee7aa0d83488e2affef927
|
|
@@ -80,7 +80,7 @@ module Reality #nodoc
|
|
|
80
80
|
|
|
81
81
|
|
|
82
82
|
helpers = template_set_container.derive_default_helpers(options.merge(:file_type => file_extension, :artifact_type => artifact_type, :facet_key => self.facet_key)) +
|
|
83
|
-
|
|
83
|
+
(options[:helpers].nil? ? [] : options[:helpers])
|
|
84
84
|
|
|
85
85
|
if 'erb' == template_extension
|
|
86
86
|
template_set.erb_template(facets,
|
|
@@ -106,13 +106,16 @@ module Reality #nodoc
|
|
|
106
106
|
def facet_directory
|
|
107
107
|
@facet_directory ||= nil
|
|
108
108
|
if @facet_directory.nil?
|
|
109
|
-
caller_locations
|
|
110
|
-
|
|
111
|
-
|
|
109
|
+
locations = respond_to?(:caller_locations) ?
|
|
110
|
+
caller_locations.collect { |c| c.absolute_path } :
|
|
111
|
+
caller.collect { |s| s.split(':')[0] }
|
|
112
|
+
locations.each do |location|
|
|
113
|
+
if location =~ /.*\/#{self.facet_key}\/model\.rb$/
|
|
114
|
+
@facet_directory = File.dirname(location)
|
|
112
115
|
break
|
|
113
116
|
end
|
|
114
117
|
end
|
|
115
|
-
Reality::Generators.error("Unable to locate facet_directory for facet #{self.facet_key}. Caller trace: #{
|
|
118
|
+
Reality::Generators.error("Unable to locate facet_directory for facet #{self.facet_key}. Caller trace: #{locations.inspect}") if @facet_directory.nil?
|
|
116
119
|
end
|
|
117
120
|
@facet_directory
|
|
118
121
|
end
|
data/reality-generators.gemspec
CHANGED