diff options
| author | Johannes Hofmann <Johannes.Hofmann@gmx.de> | 2026-11-10 09:12:35 +0100 |
|---|---|---|
| committer | Johannes Hofmann <Johannes.Hofmann@gmx.de> | 2026-11-10 09:12:35 +0100 |
| commit | 0b0663e0c9dc664f35ffead3b395ffd2009fd98c (patch) | |
| tree | f9e10437ebe7e13e527ce1a6a2b456c105bcc5c0 /crates/gipfel-desktop/build-frontend.sh | |
| parent | 02546370ec4458eef59a8f636fe05b57961d56ab (diff) | |
| parent | 31a47fc4393856a0a0380b2fdcf79f9dac72ad56 (diff) | |
Merge branch 'wasm-spike'
# Conflicts:
# crates/gipfel-core/src/metadata.rs
Diffstat (limited to 'crates/gipfel-desktop/build-frontend.sh')
| -rwxr-xr-x | crates/gipfel-desktop/build-frontend.sh | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/crates/gipfel-desktop/build-frontend.sh b/crates/gipfel-desktop/build-frontend.sh new file mode 100755 index 0000000..72a1687 --- /dev/null +++ b/crates/gipfel-desktop/build-frontend.sh @@ -0,0 +1,15 @@ +#!/bin/sh +# Build the gipfel WASM front end into dist/ for tauri to bundle. +# Runs from crates/gipfel-desktop (tauri beforeBuildCommand). +set -e +HERE="$(cd "$(dirname "$0")" && pwd)" +DIST="$HERE/dist" +mkdir -p "$DIST" +cd "$HERE/../.." +cargo build -p gipfel --target wasm32-unknown-unknown --release +wasm-bindgen --target web --out-dir "$DIST" \ + target/wasm32-unknown-unknown/release/gipfel.wasm +cp crates/gipfel/www/index.html crates/gipfel/www/style.css \ + crates/gipfel/www/loader.js "$DIST/" +gzip -9 -n -c gipfel.dat > "$DIST/gipfel.dat.gz" +echo "frontend dist ready: $DIST" |
