yaml_recrypt 0.1.2 → 0.1.3

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f16d4e879ea73da0905ca4dbb84722491a8bfaf4
4
- data.tar.gz: 97c6b54e0bdb44b94977e29968a624e646ad1364
3
+ metadata.gz: 01ac6e66f871130fed93617742163255154a08b1
4
+ data.tar.gz: 6b943ea7b16dace9b4ac9ba27a6fd2607b31354e
5
5
  SHA512:
6
- metadata.gz: 584f03df9db3301acef41bb8efb9917fb70f45669257828c863f27ed808e61c768cb675f81ca8e0ff0a8c5ee9cf3c04ad0887c85bc9b8588e63c5dcd7f8fd516
7
- data.tar.gz: b65779783c65631418d3503f25c76f9b132d7240eefa3b00c62057cffd663f9d0abe0382a2a560c899f91f908f2dbd18942c8123aeef81a99582646fa37724e2
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
- split = value.split("\n")
79
-
80
- # PGP values are always broken onto newlines
81
- if split[0].strip == '' and split[1].strip == GPG_MAGIC
82
- value = recrypt(value, gpg_home, eyaml_pub_key)
83
- changed = 1
84
- else
85
- changed = 0
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
@@ -1,3 +1,3 @@
1
1
  module YamlRecrypt
2
- VERSION = "0.1.2"
2
+ VERSION = "0.1.3"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: yaml_recrypt
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Geoff Williams