yaml_recrypt 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/yaml_recrypt.rb +9 -8
- data/lib/yaml_recrypt/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: 01ac6e66f871130fed93617742163255154a08b1
|
4
|
+
data.tar.gz: 6b943ea7b16dace9b4ac9ba27a6fd2607b31354e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4b7c0470abf504204f912fcdad39f4949950cbb4181349ddb0d37e125d713c35f514ff13f486e37b2c8c592107a8970fe21d7711f536d3405abbb0a39e7d6625
|
7
|
+
data.tar.gz: b3d2f41027ec2fe1bd28b81dcbd48f4bd686bb8d76b2b884cdbe6e47f8fdb41008adb40af795194cace4fdda30c8f55c62d7f8c861486c01efbf235e25ec94aa
|
data/lib/yaml_recrypt.rb
CHANGED
@@ -75,14 +75,15 @@ module YamlRecrypt
|
|
75
75
|
end
|
76
76
|
|
77
77
|
def self.process_value(value, gpg_home, eyaml_pub_key)
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
78
|
+
changed = 0
|
79
|
+
if value.class == String
|
80
|
+
split = value.split("\n")
|
81
|
+
|
82
|
+
# PGP values are always broken onto newlines
|
83
|
+
if split[0].strip == '' and split[1].strip == GPG_MAGIC
|
84
|
+
value = recrypt(value, gpg_home, eyaml_pub_key)
|
85
|
+
changed = 1
|
86
|
+
end
|
86
87
|
end
|
87
88
|
|
88
89
|
return changed, value
|
data/lib/yaml_recrypt/version.rb
CHANGED