Flips yaml input to json and vice versa
Project description
flamel - flip YAML to JSON, and/or JSON to YAML
Just like Nicholas Flamel, who could simply grab a pile of lead and turn it in to gold when he needed gold, flamel will turn your pile of YAML in to JSON when you need JSON. It will also turn your JSON in to YAML if that's what you want it to do.
A few features:
- Tries to detect input and flip to the alternative
- Maintains the order of keys in mappings from input to output
Install
Flamel is available in the cheese shop: https://pypi-hypernode.com/project/flamel/
You can install it with pip install flamel
See it in action
$ cat foo.yaml
things:
- thing1
- thing2
other:
mapping: 9999
$ flamel foo.yaml
{
"things": [
"thing1",
"thing2"
],
"other": {
"mapping": 9999
}
}
$ flamel foo.yaml > foo.json
$ flamel foo.json
things:
- thing1
- thing2
other:
mapping: 9999
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
flamel-0.2.1.tar.gz
(7.3 kB
view details)
File details
Details for the file flamel-0.2.1.tar.gz
.
File metadata
- Download URL: flamel-0.2.1.tar.gz
- Upload date:
- Size: 7.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/40.4.3 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.6.8
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | de8f5047c89cfb1d7e7b8e808fbae189ce25a195f68633972d4a236d84d5def2 |
|
MD5 | 26f84032b6a65db0ba6edf17c84707bf |
|
BLAKE2b-256 | 2397484b02359f4f54edbf6ae1a781c13013ea8c771b30ec9af73010f080f235 |