#!/bin/sh mkdir -p app for i in $(seq 0 $(expr $(jq '. | length' < apps.json) - 1)); do jq ".[$i]" < apps.json > app/data.json cd app #rm -rf * mkdir -p src for t in ../template/src/*; do $HOME/bin/gotempl --data-json data.json< $t > src/$(basename $t) done cp -r ../template/src-tauri . $HOME/bin/gotempl --data-json data.json< ../template/src-tauri/Cargo.toml > src-tauri/Cargo.toml $HOME/bin/gotempl --data-json data.json< ../template/src-tauri/tauri.conf.json > src-tauri/tauri.conf.json cd src-tauri cargo tauri build cargo tauri build --target i686-pc-windows-msvc cd .. cd .. done