From 8cbfa4d9883b56f2cb3a15608c467c082bf6b2f7 Mon Sep 17 00:00:00 2001 From: Stephan Renatus Date: Thu, 29 Mar 2018 15:06:55 +0200 Subject: [PATCH] [jo] add README.md This is for #1252. Signed-off-by: Stephan Renatus --- jo/README.md | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 jo/README.md diff --git a/jo/README.md b/jo/README.md new file mode 100644 index 0000000000..1bc1953bfb --- /dev/null +++ b/jo/README.md @@ -0,0 +1,39 @@ +# jo + +This package provides the jo binary. + +[jo](https://github.com/jpmens/jo) is a utility to create JSON objects on the +command line. + +## Maintainers + +The Habitat Maintainers humans@habitat.sh + +## Type of Package + +[binary wrapper package](https://www.habitat.sh/docs/best-practices/#binary-wrapper-packages) + +## Usage + +``` +$ hab pkg install core/jo +$ hab pkg binlink core/jo +$ jo -h +Usage: jo [-a] [-B] [-p] [-v] [-V] [word...] + word is key=value or key@value + -a creates an array of words + -B disable boolean true/false + -p pretty-prints JSON on output + -v show version + -V show version in JSON jo +$ jo -p foo=bar baz=$(jo -a x y z) true@1 +{ + "foo": "bar", + "baz": [ + "x", + "y", + "z" + ], + "true": true +} +```