Skip to content

Commit

Permalink
fix(find): correctly display json output in pretty format
Browse files Browse the repository at this point in the history
damienbutt committed Nov 22, 2024
1 parent 10050f0 commit 96a8937
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/actions/find.ts
Original file line number Diff line number Diff line change
@@ -62,10 +62,13 @@ export const find = {
}

if (args.json) {
const json = JSON.stringify(devices);

console.log(
await jq.run(".", JSON.stringify(devices), {
await jq.run(".", json, {
color: true,
input: "json",
input: "string",
output: "pretty",
}),
);

0 comments on commit 96a8937

Please sign in to comment.