hc
2023-12-09 b22da3d8526a935aa31e086e63f60ff3246cb61c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/bin/sh -e
 
# Enable this to save spaces
# DUMP_OPTS="--unformat"
 
# Generate template JSON
./dump --template $DUMP_OPTS > .j2s_template.json
 
# Generate template JSON C header
xxd -iu .j2s_template.json .j2s_template_json.h
{
   echo "#if 0 // Template JSON:"
   cat .j2s_template.json
   echo "#endif"
   echo
 
   cat .j2s_template_json.h
} > $1