1
mirror of https://github.com/revanced/revanced-patcher synced 2025-11-05 20:32:28 +01:00

Compare commits

...

5 Commits

Author SHA1 Message Date
dependabot[bot]
29af0c9981 build(deps-dev): Bump semantic-release from 24.2.9 to 25.0.1
Bumps [semantic-release](https://github.com/semantic-release/semantic-release) from 24.2.9 to 25.0.1.
- [Release notes](https://github.com/semantic-release/semantic-release/releases)
- [Commits](https://github.com/semantic-release/semantic-release/compare/v24.2.9...v25.0.1)

---
updated-dependencies:
- dependency-name: semantic-release
  dependency-version: 25.0.1
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-01 06:04:11 +00:00
semantic-release-bot
3a8b2ba935 chore: Release v21.1.0-dev.5 [skip ci]
# [21.1.0-dev.5](https://github.com/ReVanced/revanced-patcher/compare/v21.1.0-dev.4...v21.1.0-dev.5) (2025-10-16)
2025-10-16 15:03:36 +00:00
dependabot[bot]
39c5a66ce3 build(Needs bump): Bump dependencies 2025-10-16 17:01:58 +02:00
semantic-release-bot
b160a2adc0 chore: Release v21.1.0-dev.4 [skip ci]
# [21.1.0-dev.4](https://github.com/ReVanced/revanced-patcher/compare/v21.1.0-dev.3...v21.1.0-dev.4) (2025-07-18)

### Bug Fixes

* Correctly save XML files in UTF-8 by using a bufferedWriter ([#356](https://github.com/ReVanced/revanced-patcher/issues/356)) ([33fadcb](33fadcbd0c))
2025-07-18 19:33:42 +00:00
kitadai31
33fadcbd0c fix: Correctly save XML files in UTF-8 by using a bufferedWriter (#356) 2025-07-18 21:31:51 +02:00
9 changed files with 3999 additions and 734 deletions

View File

@@ -12,12 +12,12 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
with:
fetch-depth: 0
- name: Cache Gradle
uses: burrunan/gradle-cache-action@v1
uses: burrunan/gradle-cache-action@v3
- name: Build
env:

View File

@@ -15,7 +15,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
- name: Open pull request
uses: repo-sync/pull-request@v2

View File

@@ -16,7 +16,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@v5
with:
# Make sure the release step uses its own credentials:
# https://github.com/cycjimmy/semantic-release-action#private-packages
@@ -24,7 +24,7 @@ jobs:
fetch-depth: 0
- name: Cache Gradle
uses: burrunan/gradle-cache-action@v1
uses: burrunan/gradle-cache-action@v3
- name: Build
env:
@@ -32,7 +32,7 @@ jobs:
run: ./gradlew build clean
- name: Setup Node.js
uses: actions/setup-node@v4
uses: actions/setup-node@v5
with:
node-version: "lts/*"
cache: 'npm'

View File

@@ -1,3 +1,12 @@
# [21.1.0-dev.5](https://github.com/ReVanced/revanced-patcher/compare/v21.1.0-dev.4...v21.1.0-dev.5) (2025-10-16)
# [21.1.0-dev.4](https://github.com/ReVanced/revanced-patcher/compare/v21.1.0-dev.3...v21.1.0-dev.4) (2025-07-18)
### Bug Fixes
* Correctly save XML files in UTF-8 by using a bufferedWriter ([#356](https://github.com/ReVanced/revanced-patcher/issues/356)) ([33fadcb](https://github.com/ReVanced/revanced-patcher/commit/33fadcbd0c7076b848bdca4d62a9c684d5781232))
# [21.1.0-dev.3](https://github.com/ReVanced/revanced-patcher/compare/v21.1.0-dev.2...v21.1.0-dev.3) (2025-06-20)

View File

@@ -1,3 +1,3 @@
org.gradle.parallel = true
org.gradle.caching = true
version = 21.1.0-dev.3
version = 21.1.0-dev.5

View File

@@ -1,14 +1,14 @@
[versions]
android = "4.1.1.4"
apktool-lib = "2.10.1.1"
binary-compatibility-validator = "0.15.1"
binary-compatibility-validator = "0.18.1"
kotlin = "2.0.20"
kotlinx-coroutines-core = "1.8.1"
mockk = "1.13.10"
kotlinx-coroutines-core = "1.10.2"
mockk = "1.14.5"
multidexlib2 = "3.0.3.r3"
# Tracking https://github.com/google/smali/issues/64.
#noinspection GradleDependency
smali = "3.0.8"
smali = "3.0.9"
xpp3 = "1.1.4c"
[libraries]

4681
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@@ -4,6 +4,6 @@
"@semantic-release/changelog": "^6.0.3",
"@semantic-release/git": "^10.0.1",
"gradle-semantic-release-plugin": "^1.10.1",
"semantic-release": "^24.1.2"
"semantic-release": "^25.0.1"
}
}

View File

@@ -4,7 +4,6 @@ import org.w3c.dom.Document
import java.io.Closeable
import java.io.File
import java.io.InputStream
import java.io.StringWriter
import javax.xml.parsers.DocumentBuilderFactory
import javax.xml.transform.OutputKeys
import javax.xml.transform.TransformerFactory
@@ -36,20 +35,22 @@ class Document internal constructor(
readerCount.remove(it)
}
it.outputStream().buffered().use { stream ->
val transformer = TransformerFactory.newInstance().newTransformer()
// Set to UTF-16 but encode as UTF-8 to prevent surrogate pairs from being escaped to broken numeric character references.
if (isAndroid) {
transformer.setOutputProperty(OutputKeys.ENCODING, "UTF-16")
transformer.setOutputProperty(OutputKeys.OMIT_XML_DECLARATION, "yes")
val transformer = TransformerFactory.newInstance().newTransformer()
// Set to UTF-16 to prevent surrogate pairs from being escaped to invalid numeric character references, but save as UTF-8.
if (isAndroid) {
transformer.setOutputProperty(OutputKeys.ENCODING, "UTF-16")
transformer.setOutputProperty(OutputKeys.OMIT_XML_DECLARATION, "yes")
it.bufferedWriter(charset = Charsets.UTF_8).use { writer ->
transformer.transform(DOMSource(this), StreamResult(writer))
}
transformer.transform(DOMSource(this), StreamResult(stream))
} else {
transformer.transform(DOMSource(this), StreamResult(it))
}
}
}
private companion object {
private val readerCount = mutableMapOf<File, Int>()
private val isAndroid = System.getProperty("java.runtime.name").equals("Android Runtime")
private val isAndroid = System.getProperty("java.runtime.name") == "Android Runtime"
}
}