update service.sh

This commit is contained in:
KOWX712
2024-10-20 21:43:20 +08:00
committed by GitHub
parent fd029a8b8e
commit 21b3c9a3bc

View File

@@ -1,18 +1,15 @@
MODDIR=${0%/*}
COMPATH="$MODDIR/common"
# Check pm command functionality
sleep 10
until pm list packages > /dev/null 2>&1; do
sleep 1
done
# Check tricky store status
TS="/data/adb/modules/tricky_store"
if [ -f "$TS/disable" ]; then
cat "$COMPATH/disabled" > "$MODDIR/module.prop"
elif [ ! -d "$TS" ]; then
if [ ! -d "$TS" ]; then
cat "$COMPATH/ninstalled" > "$MODDIR/module.prop"
elif [ -f "$TS/disable" ]; then
cat "$COMPATH/disabled" > "$MODDIR/module.prop"
else
cat "$COMPATH/normal" > "$MODDIR/module.prop"
sh "$MODDIR"/common/UpdateTargetList.sh || true
until [ "$(getprop sys.boot_completed)" = "1" ]; do
sleep 1
done
. "$COMPATH/common/UpdateTargetList.sh"
fi