Skip to content

Commit 46fbe42

Browse files
inject.sh: Fix messages on Bash, Linux
1 parent d15c9e3 commit 46fbe42

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

inject.sh

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ fi
2828
if ! [ -f "./$ORIGINAL_IPA_NAME" ]; then
2929
echo "The original.ipa file doesn't exist. This script can automatically download it from archive.org."
3030
echo "Note: this file contains copyrighted materials that will be injected into the resulting app."
31-
echo "\033[0;31m$(tput bold)You CANNOT distribute the resulting $IPA_NAME file in any way. For personal use only.$(tput sgr0)\033[0m"
31+
printf "\033[0;31m$(tput bold)You CANNOT distribute the resulting $IPA_NAME file in any way. For personal use only.$(tput sgr0)\033[0m\n"
3232
while [ "$choice" != "n" ] && [ "$choice" != "y" ]; do
3333
printf "Do you want to continue? [y/n]: "
3434
read choice
@@ -44,6 +44,7 @@ if ! [ -f "./$ORIGINAL_IPA_NAME" ]; then
4444
fi
4545
fi
4646

47+
# Check file's checksum
4748
if [ "`openssl dgst -sha256 "./$ORIGINAL_IPA_NAME" | sed -E 's/SHA(2-)?256(.*)= //'`" != "$ORIGINAL_IPA_SHA256" ]; then
4849
echo "$ORIGINAL_IPA_NAME has an unexpected checksum. Try downloading it again."
4950
exit 1
@@ -95,4 +96,4 @@ echo "Injecting files into iloveusomuch.ipa..."
9596
zip -ru "$IPA_NAME" Payload > /dev/null
9697
rm -R ./Payload
9798

98-
echo "\nIPA is ready!"
99+
printf "\nIPA is ready!\n"

0 commit comments

Comments
 (0)