Merge pull request #1 from SpotX-CLI/jetfir3-patch-1

Improve xpui detection
This commit is contained in:
jetfir3 2022-10-21 11:59:58 -04:00 committed by GitHub
commit 812e16706b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -96,7 +96,11 @@ echo "SpotX-Linux by @SpotX-CLI"
echo "**************************" echo "**************************"
echo echo
# Handle xpui.bak and FORCE_FLAG logic # xpui detection
if [[ ! -f "${XPUI_SPA}" ]]; then
echo "xpui not found, skipping xpui patches..."
XPUI_SKIP="true"
else
if [[ "${FORCE_FLAG}" == "false" ]]; then if [[ "${FORCE_FLAG}" == "false" ]]; then
if [[ -f "${XPUI_BAK}" ]]; then if [[ -f "${XPUI_BAK}" ]]; then
echo "SpotX backup found, SpotX has already been used on this install." echo "SpotX backup found, SpotX has already been used on this install."
@ -116,7 +120,7 @@ else
else else
echo "Creating xpui backup..." echo "Creating xpui backup..."
cp "${XPUI_SPA}" "${XPUI_BAK}" cp "${XPUI_SPA}" "${XPUI_BAK}"
XPUI_SKIP="false"; fi; fi XPUI_SKIP="false"; fi; fi; fi
# Extract xpui.spa # Extract xpui.spa
if [[ "${XPUI_SKIP}" == "false" ]]; then if [[ "${XPUI_SKIP}" == "false" ]]; then