55f3196c4b3e343a573a93c59e557cd076236dd0
json2excel
This is a basic utility to take json and convert it into an OpenXml format xlsx file, compatible with Excel.
It expects that the json input is formatted as an object containing an array of objects. Column names are generated based on the keys in the first nested object.
Command line options
Parameter | Default Value | Description |
---|---|---|
inputJson | input.json | File path of the input json to process |
outputFilename | output.xlsx | File path of the output file |
worksheetName | Sheet1 | Set the name of the worksheet, will be truncated to 31 characters |
boldTopRow | true | Sets the top row of the worksheet to bold |
freezeTopRow | true | Freezes the first row of the Excel worksheet |
autofilter | true | Sets the auto filter on the first row |
autowidth | true | Automatically set the column width to fit contents |
Advanced configuration
Key | Example Value | Description |
---|---|---|
key-order | "Column3,Column1,Column2" | Comma separated list of column names in the desired order |
overwrite-file | true | Boolean indicating whether output file should be overwritten if it already exists |
Advanced settings can be provided via a top level json key named "config". Here is a table of options that can be set via this config key.
Description
Golang upgrades
Latest
Languages
Go
100%