Created
August 15, 2017 14:30
-
-
Save devster31/21bdeba2d8bf8f905d3256e0f902845b to your computer and use it in GitHub Desktop.
oneliner to dump YAML to JSON
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/ruby | |
# ruby -ryaml -rjson -e 'puts YAML.load($stdin.read).to_json' | |
require 'json' | |
require 'yaml' | |
puts YAML.load($stdin.read).to_json |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment