AK3: add no_magisk_check=1 to skip Magisk detection and repatching

This commit is contained in:
Chris Renshaw authored and GitHub committed 2023-08-15 20:08:55 -03:00
1 parent 86417ffcb3
commit 9d09ba3ecd
2 files changed
+6 -4

No files matched your search

+1 -1
View File
@@ -3,4 +3,4 @@
# Dummy file; update-binary is a shell script (DO NOT CHANGE) # Dummy file; update-binary is a shell script (DO NOT CHANGE)
# #
# #
# AK_BASE_VERSION=20230810 # AK_BASE_VERSION=20230815
+5 -3
View File
@@ -212,8 +212,10 @@ repack_ramdisk() {
[ $? != 0 ] && packfail=1; [ $? != 0 ] && packfail=1;
cd $home; cd $home;
$bin/magiskboot cpio ramdisk-new.cpio test; if [ ! "$no_magisk_check" ]; then
magisk_patched=$?; $bin/magiskboot cpio ramdisk-new.cpio test;
magisk_patched=$?;
fi;
[ $((magisk_patched & 3)) -eq 1 ] && $bin/magiskboot cpio ramdisk-new.cpio "extract .backup/.magisk $split_img/.magisk"; [ $((magisk_patched & 3)) -eq 1 ] && $bin/magiskboot cpio ramdisk-new.cpio "extract .backup/.magisk $split_img/.magisk";
if [ "$comp" ]; then if [ "$comp" ]; then
$bin/magiskboot compress=$comp ramdisk-new.cpio; $bin/magiskboot compress=$comp ramdisk-new.cpio;
@@ -315,7 +317,7 @@ flash_boot() {
done; done;
case $kernel in case $kernel in
*Image*) *Image*)
if [ ! "$magisk_patched" ]; then if [ ! "$magisk_patched" -a ! "$no_magisk_check" ]; then
$bin/magiskboot cpio ramdisk.cpio test; $bin/magiskboot cpio ramdisk.cpio test;
magisk_patched=$?; magisk_patched=$?;
fi; fi;