Skip to content

Commit

Permalink
Add build cleaning
Browse files Browse the repository at this point in the history
  • Loading branch information
FrederickGeek8 committed Jun 29, 2018
1 parent caa51fb commit 27fb1d5
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 3 deletions.
12 changes: 11 additions & 1 deletion gendeb.sh
Original file line number Diff line number Diff line change
@@ -1,10 +1,19 @@
#!/bin/bash
if ! which unipkg &> /dev/null; then
echo "unipkg is not installed. Install with npm install -g unipkg."
exit 1
fi

OUTDIR=./dist/out.xcarchive
ORIG=$(pwd)

# Cleanup
if [ -d "$OUTDIR" ]; then
echo "Cleaning previous build..."
rm -r $OUTDIR
fi


xcodebuild -workspace iNDS.xcworkspace -scheme iNDS archive CODE_SIGNING_REQUIRED=NO CODE_SIGN_IDENTITY="" -archivePath "$OUTDIR" | xcpretty
if [ ${PIPESTATUS[0]} -eq 0 ]; then
cd "$OUTDIR/Products"
Expand All @@ -14,6 +23,7 @@ if [ ${PIPESTATUS[0]} -eq 0 ]; then
cd ..
INDS_VER=$INDS_VER unipkg build "Products"
cp "net.nerd.iNDS_${INDS_VER}_iphoneos-arm.deb" ../
echo -e "\nThe deb can be found at dist/net.nerd.iNDS_${INDS_VER}_iphoneos-arm.deb"
else
echo "\nBuild failed!"
echo -e "\nBuild failed!"
fi
12 changes: 10 additions & 2 deletions genipa.sh
Original file line number Diff line number Diff line change
@@ -1,13 +1,21 @@
#!/bin/bash
OUTDIR=./dist/out.xcarchive
ORIG=$(pwd)

# Cleanup
if [ -d "$OUTDIR" ]; then
echo "Cleaning previous build..."
rm -r $OUTDIR
fi

xcodebuild -workspace iNDS.xcworkspace -scheme iNDS archive CODE_SIGNING_REQUIRED=NO CODE_SIGN_IDENTITY="" -archivePath "$OUTDIR" | xcpretty
if [ ${PIPESTATUS[0]} -eq 0 ]; then
cd "$OUTDIR/Products"
mv "Applications" "Payload"
zip -r "iNDS.ipa" "Payload"
cp "iNDS.ipa" ../../
cd $ORIG
echo "\nThe unsigned IPA can be found at dist/iNDS.ipa"
echo -e "\nThe unsigned IPA can be found at dist/iNDS.ipa"
else
echo "\nBuild failed!"
echo -e "\nBuild failed!"
fi

0 comments on commit 27fb1d5

Please sign in to comment.