Skip to content

Commit

Permalink
reformat json string
Browse files Browse the repository at this point in the history
  • Loading branch information
Jason2866 committed Dec 21, 2023
1 parent 9ef6697 commit 531f9a6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions build-zip.sh
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ JSON_STRING=$( jq -n \
--argjson fs_file_size $fs_file_size \
--arg fs_cs_sha1 "$fs_file_cs1" \
--arg fs_cs_sha256 "$fs_file_cs256" \
'{ "name" : $name, "platform" : $platform, "version" : $version, "build_id" : $build_id, "build_timestamp" : $build_timestamp, "parts": { "app": { "type": "app", "src": $app_file, "size": $app_file_size, "cs_sha1" : $app_cs_sha1, "cs_sha256" : $app_cs_sha256, "encrypt": true, "ptn": "app_0"}, "boot": { "type": "boot", "src": $boot_file, "addr": $boot_file_addr, "size": $boot_file_size, "cs_sha1" : $boot_cs_sha1, "cs_sha256": $boot_cs_sha256, "encrypt": true, "update": true }, "fs": { "type": "fs", "src": $fs_file, "size": $fs_file_size, "cs_sha1": $fs_cs_sha1, "cs_sha256": $fs_cs_sha256, "fs_size": $fs_file_size, "encrypt": true, "ptn": "fs_1" }, "nvs": { "type": "nvs", "size": 16384, "fill": 255, "ptn": "nvs" }, "otadata": { "type": "otadata", "src": $otadata_file, "size": $otadata_file_size, "cs_sha1": $otadata_cs_sha1, "cs_sha256": $otadata_cs_sha256, "encrypt": true, "ptn": "otadata"}, "pt": { "type": "pt", "src": $partition_file, "addr": 32768, "size": $partition_file_size, "cs_sha1": $partition_cs_sha1, "cs_sha256": $partition_cs_sha256, "encrypt": true }}}')
'{ "name" : $name, "platform" : $platform, "version" : $version, "build_id" : $build_id, "build_timestamp" : $build_timestamp, "parts": { "boot": { "type": "boot", "src": $boot_file, "addr": $boot_file_addr, "size": $boot_file_size, "cs_sha1" : $boot_cs_sha1, "cs_sha256": $boot_cs_sha256, "encrypt": true, "update": true }, "pt": { "type": "pt", "src": $partition_file, "addr": 32768, "size": $partition_file_size, "cs_sha1": $partition_cs_sha1, "cs_sha256": $partition_cs_sha256, "encrypt": true }, "otadata": { "type": "otadata", "src": $otadata_file, "size": $otadata_file_size, "cs_sha1": $otadata_cs_sha1, "cs_sha256": $otadata_cs_sha256, "encrypt": true, "ptn": "otadata"}, "nvs": { "type": "nvs", "size": 16384, "fill": 255, "ptn": "nvs" }, "app": { "type": "app", "src": $app_file, "size": $app_file_size, "cs_sha1" : $app_cs_sha1, "cs_sha256" : $app_cs_sha256, "encrypt": true, "ptn": "app_0"}, "fs": { "type": "fs", "src": $fs_file, "size": $fs_file_size, "cs_sha1": $fs_cs_sha1, "cs_sha256": $fs_cs_sha256, "fs_size": $fs_file_size, "encrypt": true, "ptn": "fs_1" }}}')
printf "$JSON_STRING" > build-files/manifest.json
Expand All @@ -94,7 +94,7 @@ cd ..
printf "\nDone mgos32-to-tasmota32-$shelly_device.zip\n\n"
}
}
ShellyPlusMini=( Plus1PMMini Plus1Mini PlusPMMini )
for i in "${ShellyPlusMini[@]}"
Expand Down

0 comments on commit 531f9a6

Please sign in to comment.