classy-yaml 0.8.0 → 0.8.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/classy/yaml/component_helpers.rb +5 -3
- data/lib/classy/yaml/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1a317b7d0d4d98ba75bede21873cab424ae0238336fbd61a3425240d9972824a
|
4
|
+
data.tar.gz: e42bba9cb118a3805da435e1737bad5000ca1b181104eb5ddfabc194f7472ebd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3dce1e8ae1e7174381890149634d25b820f46d786451cc128437a8b5e960bc6f5729d9b38de6ad7ceb712494dee3237d04d3b5658b27730c9110de0608dbea26
|
7
|
+
data.tar.gz: 15740e73a3143adc07ef903f7dfebf31e3bb20ef89b621776f207b1e9afa5874b314be84dc8df1ebf90f48fb9a7603ac956cf8c02f0327ee399711e73557c45a
|
@@ -2,10 +2,12 @@ module Classy
|
|
2
2
|
module Yaml
|
3
3
|
module ComponentHelpers
|
4
4
|
def yass(*args)
|
5
|
-
component_name = self.class.source_location.split("/").last.split(".").first
|
6
5
|
calling_path = self.class.source_location.split("/")[0...-1].join("/")
|
7
|
-
|
8
|
-
|
6
|
+
calling_file = self.class.source_location.split("/").last.split(".").first
|
7
|
+
component_name = self.class.name.underscore.split("/").last.split(".").first
|
8
|
+
|
9
|
+
classy_file = if Dir.exist?("#{calling_path}/#{calling_file}")
|
10
|
+
"#{calling_path}/#{calling_file}/#{component_name}.yml"
|
9
11
|
else
|
10
12
|
"#{calling_path}/#{component_name}.yml"
|
11
13
|
end
|
data/lib/classy/yaml/version.rb
CHANGED