figaro2eb 0.0.4 → 1.0.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/figaro2eb.rb +9 -1
- data/lib/figaro2eb/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: d2ba540ef412e8f73acdd09a879cac424bd0b653
|
|
4
|
+
data.tar.gz: 9fddc9789b20f252bffa5a905762b51e9986096f
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 8d4c7d00fab20e9e8c7b9ebb8a28ed8ecd3073c3dff18a8645a435b16d3e2619c92dcdda4c1e90eac6ab09f2373dc574db91e68141c583b0ca6d6dab6aa4d79e
|
|
7
|
+
data.tar.gz: 4951d16e0ee9a02b8c5704eb0321ccb6d0aa8907c45c510bc5e3dd626e4d645e53333321eb5a7b3b9814550049a07839634edbaf50fcec8126ea4f4a81179c49
|
data/lib/figaro2eb.rb
CHANGED
|
@@ -82,11 +82,19 @@ module Figaro2eb
|
|
|
82
82
|
|
|
83
83
|
def push_environment_keys key
|
|
84
84
|
@keys[key].each do |key, value|
|
|
85
|
-
|
|
85
|
+
self.check_value key, value
|
|
86
86
|
self.check_if_value_empty key, value
|
|
87
87
|
end
|
|
88
88
|
end
|
|
89
89
|
|
|
90
|
+
def check_value key, value
|
|
91
|
+
if (/^[a-zA-Z0-9\-.:\/@+-]*$/.match(value))
|
|
92
|
+
@script.write("#{key}='#{value}' ")
|
|
93
|
+
else
|
|
94
|
+
puts "The value of #{key} contains special characters that are not allowed by setvar. You will have to manually add this to the EB configuration."
|
|
95
|
+
end
|
|
96
|
+
end
|
|
97
|
+
|
|
90
98
|
def check_if_value_empty key, value
|
|
91
99
|
if value.is_a?(String) && value.empty?
|
|
92
100
|
puts "The value of #{key} is empty. You will have to manually add this to the EB configuration."
|
data/lib/figaro2eb/version.rb
CHANGED