-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.sh
More file actions
executable file
·35 lines (31 loc) · 1.56 KB
/
build.sh
File metadata and controls
executable file
·35 lines (31 loc) · 1.56 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#!/usr/bin/env bash
# build.sh — build MultiChannelWavMixer.app with PyInstaller via uv
# Usage:
# ./build.sh — normal build
# ./build.sh --clean — remove dist/ and build/ first, then build
set -euo pipefail
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
cd "$SCRIPT_DIR"
# ── Optional clean ──────────────────────────────────────────────────────────────
if [[ "${1:-}" == "--clean" ]]; then
echo "→ Cleaning previous build artefacts …"
rm -rf dist build __pycache__
fi
# ── Build ───────────────────────────────────────────────────────────────────────
echo "→ Building MultiChannelWavMixer.app …"
uv run pyinstaller MultiChannelWavMixer.spec \
--noconfirm \
--log-level WARN
# ── Result ──────────────────────────────────────────────────────────────────────
APP="dist/MultiChannelWavMixer.app"
if [[ -d "$APP" ]]; then
SIZE=$(du -sh "$APP" | cut -f1)
echo ""
echo "✓ Build successful: $APP ($SIZE)"
echo ""
echo " To run: open $APP"
echo " To zip: cd dist && zip -r MultiChannelWavMixer.zip MultiChannelWavMixer.app"
else
echo "✗ Build failed — $APP not found." >&2
exit 1
fi