1
mirror of https://github.com/revanced/revanced-patcher synced 2025-09-06 16:38:50 +02:00

Compare commits

...

3 Commits

Author SHA1 Message Date
semantic-release-bot
4507cd2353 chore(release): 1.3.2 [skip ci]
## [1.3.2](https://github.com/revanced/revanced-patcher/compare/v1.3.1...v1.3.2) (2022-06-21)

### Bug Fixes

* return resourceFile to caller ([1f75777](1f75777cf9))
2022-06-21 18:45:16 +00:00
Lucaskyy
1f75777cf9 fix: return resourceFile to caller 2022-06-21 20:43:47 +02:00
Lucaskyy
28d5468b07 build: do not propagate all dependencies 2022-06-21 20:29:37 +02:00
5 changed files with 21 additions and 10 deletions

View File

@@ -1,3 +1,10 @@
## [1.3.2](https://github.com/revanced/revanced-patcher/compare/v1.3.1...v1.3.2) (2022-06-21)
### Bug Fixes
* return resourceFile to caller ([1f75777](https://github.com/revanced/revanced-patcher/commit/1f75777cf985bf08483033ec541937d3e733347b))
## [1.3.1](https://github.com/revanced/revanced-patcher/compare/v1.3.0...v1.3.1) (2022-06-21)

View File

@@ -24,10 +24,12 @@ dependencies {
implementation(kotlin("stdlib"))
implementation(kotlin("reflect"))
api("xpp3:xpp3:1.1.4c")
api("org.apktool:apktool-lib:2.6.5-SNAPSHOT")
api("app.revanced:multidexlib2:2.5.2.r2")
api("org.smali:smali:2.5.2")
implementation("xpp3:xpp3:1.1.4c")
implementation("app.revanced:multidexlib2:2.5.2.r2")
implementation("org.smali:smali:2.5.2")
implementation("org.apktool:apktool-lib:2.6.5-SNAPSHOT")
api("org.apktool:brut.j.dir:2.6.5-SNAPSHOT")
testImplementation(kotlin("test"))
}

View File

@@ -1,2 +1,2 @@
kotlin.code.style = official
version = 1.3.1
version = 1.3.2

View File

@@ -137,6 +137,7 @@ class Patcher(private val options: PatcherOptions) {
fun save(): PatcherResult {
val packageMetadata = data.packageMetadata
val metaInfo = packageMetadata.metaInfo
var resourceFile: ExtFile? = null
if (options.patchResources) {
val cacheDirectory = ExtFile(options.resourceCacheDirectory)
@@ -177,9 +178,7 @@ class Patcher(private val options: PatcherOptions) {
null, includedFiles
)
// write packaged resources to cache directory
ExtFile(aaptFile).directory.copyToDir(cacheDirectory.resolve("build/"))
resourceFile = ExtFile(aaptFile)
}
val newDexFile = object : DexFile {
@@ -204,7 +203,8 @@ class Patcher(private val options: PatcherOptions) {
dexFiles.map {
app.revanced.patcher.util.dex.DexFile(it.key, it.value)
},
metaInfo.doNotCompress.toList()
metaInfo.doNotCompress.toList(),
resourceFile
)
}

View File

@@ -1,6 +1,7 @@
package app.revanced.patcher
import app.revanced.patcher.util.dex.DexFile
import brut.directory.ExtFile
/**
* The result of a patcher.
@@ -9,5 +10,6 @@ import app.revanced.patcher.util.dex.DexFile
*/
data class PatcherResult(
val dexFiles: List<DexFile>,
val doNotCompress: List<String>? = null
val doNotCompress: List<String>? = null,
val resourceFile: ExtFile?
)