You've already forked ReZygisk
mirror of
https://github.com/PerformanC/ReZygisk.git
synced 2025-09-06 06:37:01 +00:00
34 lines
703 B
Bash
34 lines
703 B
Bash
#!/system/bin/sh
|
|
|
|
DEBUG=@DEBUG@
|
|
|
|
MODDIR=${0%/*}
|
|
if [ "$ZYGISK_ENABLED" ]; then
|
|
exit 0
|
|
fi
|
|
|
|
cd "$MODDIR"
|
|
|
|
# temporary fix AVD 11 magisk
|
|
# if [ -f /dev/zygisk_service ];then
|
|
# log -p i -t "zygisk-sh" "service called twice";
|
|
# exit;
|
|
# fi
|
|
# touch /dev/zygisk_service
|
|
|
|
if [ "$(which magisk)" ]; then
|
|
for file in ../*; do
|
|
if [ -d "$file" ] && [ -d "$file/zygisk" ] && ! [ -f "$file/disable" ]; then
|
|
if [ -f "$file/service.sh" ]; then
|
|
cd "$file"
|
|
log -p i -t "zygisk-sh" "Manually trigger service.sh for $file"
|
|
sh "$(realpath ./service.sh)"
|
|
cd "$MODDIR"
|
|
fi
|
|
fi
|
|
done
|
|
fi
|
|
|
|
[ "$DEBUG" = true ] && export RUST_BACKTRACE=1
|
|
unshare -m sh -c "bin/zygisk-wd &"
|