mirror of
https://github.com/wasp-lang/wasp.git
synced 2024-12-25 18:13:52 +03:00
19 lines
468 B
Bash
Executable File
19 lines
468 B
Bash
Executable File
#!/bin/sh -e
|
|
|
|
# Takes already built binary from stack and packages it
|
|
# together with data into .tar.gz package.
|
|
|
|
DST=$(realpath ${1:-wasp.tar.gz})
|
|
|
|
TMP_DIR="$(mktemp -d 2>/dev/null || mktemp -d -t wasp-bin-package)"
|
|
|
|
cp "$(stack path --local-install-root)"/bin/wasp "$TMP_DIR/wasp-bin"
|
|
cp -R "$(stack path --project-root)/data" "$TMP_DIR/data"
|
|
|
|
cd "$TMP_DIR"
|
|
tar -czf "$DST" *
|
|
|
|
if [ -n "$TMP_DIR" ]; then rm -rf "$TMP_DIR"; fi
|
|
|
|
echo "Generated binary package: $DST."
|