z-tokens
z-tokens copied to clipboard
Add support for multiple output formats (JSON, zero-separated lines, etc.)
Add support for outputing in various formats (especially for generate
) for the following formats:
-
text
-- the current plain-text output format; -
text-zero
--\0
terminated lines, meant mainly for tool consumption; -
json
-- JSON as a single object / array; -
json-sequence
-- a sequence of JSON objects / arrays; (useful forjq
handling;)
(Special care must be taken to make sure we don't leak secret material while serializing. See also #8.)