Skip to content

Instantly share code, notes, and snippets.

@selvakn
Created September 12, 2018 13:35
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save selvakn/8ca9812d757cf7332f4568551c5679c2 to your computer and use it in GitHub Desktop.
Save selvakn/8ca9812d757cf7332f4568551c5679c2 to your computer and use it in GitHub Desktop.
#!/usr/bin/ruby
require 'base64'
require 'json'
secrets = JSON.parse STDIN.read
data = secrets['data']
parsed_values = data.map{|(k,v)| [k, Base64.decode64(v) ]}
puts JSON.pretty_generate Hash[parsed_values]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment