Authored by Dan Thomson

Convert JSON to YAML

This is the simplest way I've found to make the conversion.

YAML is a superset of JSON, so all valid JSON should convert successfully to YAML.

This snipped requires jq which is likely provided as a package on your Linux distribution (eg. yum install jq). If you have Python installed, you can also pip install jq (or pip3 install jq if you want to use Python 3).

It also required yq ( which is written to use jq. There probably isn't a package in your distribution for yq, but you can use pip or pip3 to install this tool.

Edited 253 Bytes
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment