squattingmonk/nasher

JSON format is unfriendly to sed and grep

Closed this issue · 2 comments

Looking at the generated JSON, if it was packed by line it would be easier to grep and sed.

ie: instead of

  "IsNight": {
    "type": "byte",
    "value": 0
  },
  "LightingScheme": {
    "type": "byte",
    "value": 7
  },

having:

  "IsNight": { "type": "byte", "value": 0 },
  "LightingScheme": { "type": "byte", "value": 7 },

I will look at reformatting the JSON. In the meantime, I would suggest piping the json through gron to get grepable output.

I'm still exploring how to change the json formatting, but there's thanks to @WilliamDraco, nasher now supports nwnt. This format is much friendlier to sed and grep and may be helpful.