From 61176368bb2200c0b6dde0f005929a5e50b6da93 Mon Sep 17 00:00:00 2001 From: Cameron Gutman Date: Sun, 6 Nov 2022 22:10:50 -0600 Subject: [PATCH] Add release build script --- do-release.sh | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100755 do-release.sh diff --git a/do-release.sh b/do-release.sh new file mode 100755 index 0000000..55996f6 --- /dev/null +++ b/do-release.sh @@ -0,0 +1,16 @@ +fail() +{ + echo "$1" 1>&2 + exit 1 +} + +git diff-index --quiet HEAD -- || fail "Release builds must not have unstaged changes!" + +rm moonlight-chrome.zip +make clean || fail "Clean failed" +make -j$(nproc) || fail "Build failed" + + +zip moonlight-chrome.zip -r . -i pnacl/Release/moonlight-chrome.* -i manifest.json -i index.html -i LICENSE || fail "Zip failed" +zip moonlight-chrome.zip -r icons || fail "Zip failed" +zip moonlight-chrome.zip -r static || fail "Zip failed" \ No newline at end of file