Skip to content
This repository has been archived by the owner on Jun 6, 2019. It is now read-only.

Commit

Permalink
Added uninstall.sh file
Browse files Browse the repository at this point in the history
  • Loading branch information
MarcAnt01 committed Apr 15, 2019
1 parent 7a38196 commit 125c1c5
Showing 1 changed file with 35 additions and 0 deletions.
35 changes: 35 additions & 0 deletions uninstall.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
#!/system/bin/sh

# MagiskHide Props Config
# Copyright (c) 2018-2019 Didgeridoohan @ XDA Developers
# Licence: MIT

# Uninstalls the module settings file and directory in Magisk's secure directory
# together with a few module files in /cache.

MODPATH=${0%/*}

# Load functions
. $MODPATH/util_functions.sh

# Variables
DIR=/data/adb/mhpc

# Start logging
log_start

log_handler "Cleaning up module files during uninstall."

if [ -d "$DIR" ]; then
log_handler "Removing settings file(s)."
echo "Deleting $DIR" >> $LOGFILE 2>&1
rm -rf "$DIR" >> $LOGFILE 2>&1
fi

log_handler "Checking for files to remove in $CACHELOC."
for ITEM in $CACHEFILES; do
if [ -f "$CACHELOC/$ITEM" ]; then
echo "Deleting ${ITEM}." >> $LOGFILE 2>&1
rm -f $CACHELOC/$ITEM >> $LOGFILE 2>&1
fi
done

0 comments on commit 125c1c5

Please sign in to comment.