mirror of
https://github.com/kmein/niveum
synced 2026-03-16 10:11:08 +01:00
feat: json2csv script
This commit is contained in:
5
.bin/json2csv.jq
Executable file
5
.bin/json2csv.jq
Executable file
@@ -0,0 +1,5 @@
|
||||
#!/usr/bin/env -S jq -r -f
|
||||
(map(keys) | add | unique) as $cols
|
||||
| map(. as $row | $cols | map($row[.])) as $rows
|
||||
| $cols, $rows[]
|
||||
| @csv
|
||||
Reference in New Issue
Block a user