mirror of
https://github.com/chiteroman/PlayIntegrityFix.git
synced 2025-01-19 11:02:20 +08:00
Added auto module zip!
This commit is contained in:
parent
34b2550bba
commit
96e201d786
3
.gitignore
vendored
3
.gitignore
vendored
@ -13,3 +13,6 @@
|
||||
.externalNativeBuild
|
||||
.cxx
|
||||
local.properties
|
||||
/module/classes.dex
|
||||
/module/zygisk/*
|
||||
/out/*
|
@ -43,3 +43,26 @@ android {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
afterEvaluate {
|
||||
val moduleFolder = project.rootDir.resolve("module")
|
||||
val dexFile = project.buildDir.resolve("intermediates/dex/release/minifyReleaseWithR8/classes.dex")
|
||||
val soDir = project.buildDir.resolve("intermediates/stripped_native_libs/release/out/lib")
|
||||
|
||||
dexFile.copyTo(moduleFolder.resolve("classes.dex"), overwrite = true)
|
||||
|
||||
soDir.walk().filter { it.isFile && it.extension == "so" }.forEach { soFile ->
|
||||
val abiFolder = soFile.parentFile.name
|
||||
val destination = moduleFolder.resolve("zygisk/$abiFolder.so")
|
||||
soFile.copyTo(destination, overwrite = true)
|
||||
}
|
||||
|
||||
tasks["assembleRelease"].dependsOn("module")
|
||||
}
|
||||
|
||||
tasks.register<Zip>("module") {
|
||||
archiveFileName.set("PlayIntegrityFix.zip")
|
||||
destinationDirectory.set(project.rootDir.resolve("out"))
|
||||
|
||||
from(project.rootDir.resolve("module"))
|
||||
}
|
Loading…
Reference in New Issue
Block a user