diff --git a/src/build/pack.sh b/src/build/pack.sh index 2f4469f..96fe5f7 100755 --- a/src/build/pack.sh +++ b/src/build/pack.sh @@ -15,6 +15,15 @@ set -e +function check_uncommitted_assets() { + ( cd assets; [ $(git status --porcelain . | wc -l) -gt 0 ] ) +} + +if check_uncommitted_assets; then + echo "Please make sure there are no uncommited files in the 'asset' directory before packing" + exit 1 +fi + if [ "$1" == "-b" ]; then cargo build --release --target=x86_64-unknown-linux-gnu --no-default-features --features release_linux cargo build --release --target=x86_64-pc-windows-gnu --no-default-features --features release_windows