action: abandon UpdateTargetList.sh

This commit is contained in:
KOWX712
2024-12-01 22:57:34 +08:00
parent 18e3048028
commit a399c4a69a
2 changed files with 3 additions and 63 deletions

View File

@@ -12,26 +12,6 @@ if pm list packages | grep -q "$PACKAGE_NAME"; then
echo "- Launching KSU WebUI..."
am start -n "${PACKAGE_NAME}/.WebUIActivity" -e id "$MODID"
else
SKIP_FILE="$SCRIPT_DIR/target_list_config/skipwebui"
if [ ! -f "$SKIP_FILE" ]; then
echo "**********************************************"
echo "- Do you want to install KSU WebUI standalone?"
echo " VOL [+]: YES"
echo " VOL [-]: NO"
echo "**********************************************"
key_check
if [[ "$keycheck" == "KEY_VOLUMEUP" ]]; then
echo "- Installing KSU WebUI..."
. "$COMPATH/get_WebUI.sh"
else
echo "- Skipping WebUI installation..."
touch "$SKIP_FILE"
echo "- Skip WebUI check until next installation."
echo ""
update_script
fi
else
update_script
fi
echo "- Installing KSU WebUI..."
. "$COMPATH/get_WebUI.sh"
fi

View File

@@ -43,44 +43,4 @@ install_webui() {
rm -f "$APK_PATH"
exit 1
fi
}
key_check() {
while true; do
key_check=$(/system/bin/getevent -qlc 1)
key_event=$(echo "$key_check" | awk '{ print $3 }' | grep 'KEY_')
key_status=$(echo "$key_check" | awk '{ print $4 }')
if [[ "$key_event" == *"KEY_"* && "$key_status" == "DOWN" ]]; then
keycheck="$key_event"
break
fi
done
while true; do
key_check=$(/system/bin/getevent -qlc 1)
key_event=$(echo "$key_check" | awk '{ print $3 }' | grep 'KEY_')
key_status=$(echo "$key_check" | awk '{ print $4 }')
if [[ "$key_event" == *"KEY_"* && "$key_status" == "UP" ]]; then
break
fi
done
}
update_script() {
echo "**********************************************"
echo "- Starting script..."
echo ""
if [[ ! -f "$SCRIPT_DIR/UpdateTargetList.sh" ]]; then
echo "! Script missing, please install module again."
echo "**********************************************"
exit 1
else
. "$SCRIPT_DIR/UpdateTargetList.sh"
fi
echo "**********************************************"
echo ""
echo "\(__All set!__)/"
echo "Exiting in 2 seconds..."
sleep 2
}
}