Skip to content

Commit

Permalink
Use negate (#3)
Browse files Browse the repository at this point in the history
* use negate

* fall through
  • Loading branch information
rickycodes committed Mar 5, 2022
1 parent 716fdfb commit 9367624
Showing 1 changed file with 17 additions and 16 deletions.
33 changes: 17 additions & 16 deletions no-subscription-warning.sh
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -38,22 +38,23 @@ apply_razor1911_crack() {

echo "attempting pve-no-subscription patch"

if [ -n "$ARG" ]; then
if [ "$ARG" == "--steamroll" ]; then
apply_razor1911_crack
else
echo "unrecognized option"
fi
else
if test -f "$FILE"; then
if grep -i "$FIND" "$FILE"; then
echo "subscription status: $FIND"
echo "attempting replacement in $FILE..."
apply_razor1911_crack
else
echo "pve appears to be patched."
fi
else
if ! [ -n "$ARG" ]; then
if ! test -f "$FILE"; then
echo "$FILE does not exist! are you sure this is pve?"
exit 0
fi

if ! grep -i "$FIND" "$FILE"; then
echo "pve appears to be patched."
exit 0
fi
fi

if ! [ "$ARG" == "--steamroll" ]; then
echo "unrecognized option"
exit 1
fi

echo "subscription status: $FIND"
echo "attempting replacement in $FILE..."
apply_razor1911_crack

0 comments on commit 9367624

Please sign in to comment.