Skip to content
Snippets Groups Projects
Commit 2cad1842 authored by Emuis's avatar Emuis
Browse files

change the exit code if tweego fails so other scripts can know the compile failed

parent 5d752e76
No related branches found
No related tags found
No related merge requests found
......@@ -12,23 +12,28 @@ ARCH="$(uname -m)"
if [ "$ARCH" = "x86_64" ]
then
echo "x64 arch"
./devTools/tweeGo/tweego_nix64 -o bin/FC_pregmod.html src/
./devTools/tweeGo/tweego_nix64 -o bin/FC_pregmod.html src/ || build_failed="true"
elif echo "$ARCH" | grep -Ee '86$' > /dev/null
then
echo "x86 arch"
./devTools/tweeGo/tweego_nix86 -o bin/FC_pregmod.html src/
./devTools/tweeGo/tweego_nix86 -o bin/FC_pregmod.html src/ || build_failed="true"
elif echo "$ARCH" | grep -Ee '^arm' > /dev/null
then
echo "arm arch"
# tweego doesn't provide arm binaries so you have to build it yourself
export TWEEGO_PATH=devTools/tweeGo/storyFormats
tweego -o bin/FC_pregmod.html src/
tweego -o bin/FC_pregmod.html src/ || build_failed="true"
else
exit 2
fi
#Make the output prettier, replacing \t with a tab and \n with a newline
sed -i -e '/^.*<div id="store-area".*$/s/\\t/\t/g' -e '/^.*<div id="store-area".*$/s/\\n/\n/g' bin/FC_pregmod.html
# Revert AlphaDisclaimer for next compilation
git checkout -- src/gui/mainMenu/AlphaDisclaimer.tw
if [ "$build_failed" = "true" ]
then
exit 1
fi
#Make the output prettier, replacing \t with a tab and \n with a newline
sed -i -e '/^.*<div id="store-area".*$/s/\\t/\t/g' -e '/^.*<div id="store-area".*$/s/\\n/\n/g' bin/FC_pregmod.html
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment