mirror of
https://github.com/tiann/KernelSU.git
synced 2025-02-20 11:43:32 +08:00
ksud: Support remove files in customize.sh by REMOVE variables.
e.g: REMOVE=" /system/app/YouTube /system/app/Bloatware "
This commit is contained in:
parent
14b2afe78d
commit
dcbbbab11e
@ -271,6 +271,12 @@ mktouch() {
|
||||
chmod 644 $1
|
||||
}
|
||||
|
||||
mark_remove() {
|
||||
mkdir -p ${1%/*} 2>/dev/null
|
||||
mknod $1 c 0 0
|
||||
chmod 644 $1
|
||||
}
|
||||
|
||||
request_size_check() {
|
||||
reqSizeM=`du -ms "$1" | cut -f1`
|
||||
}
|
||||
@ -387,6 +393,12 @@ install_module() {
|
||||
mktouch $MODPATH$TARGET/.replace
|
||||
done
|
||||
|
||||
# Handle remove files
|
||||
for TARGET in $REMOVE; do
|
||||
ui_print "- Remove target: $TARGET"
|
||||
mark_remove $MODPATH$TARGET
|
||||
done
|
||||
|
||||
if $BOOTMODE; then
|
||||
mktouch $NVBASE/modules/$MODID/update
|
||||
rm -rf $NVBASE/modules/$MODID/remove 2>/dev/null
|
||||
|
Loading…
x
Reference in New Issue
Block a user