Compare commits

..

4 Commits

Author SHA1 Message Date
semantic-release-bot
03160ccef1 chore: Release v1.26.0-dev.5 [skip ci]
# app [1.26.0-dev.5](https://github.com/ReVanced/revanced-manager/compare/v1.26.0-dev.4...v1.26.0-dev.5) (2025-10-03)

### Features

* Toggle to use pre-release versions of ReVanced Patches ([08cec67](08cec674bb))
2025-10-03 15:37:24 +00:00
Ax333l
08cec674bb feat: Toggle to use pre-release versions of ReVanced Patches 2025-10-03 17:29:06 +02:00
semantic-release-bot
95fb97ec31 chore: Release v1.26.0-dev.4 [skip ci]
# app [1.26.0-dev.4](https://github.com/ReVanced/revanced-manager/compare/v1.26.0-dev.3...v1.26.0-dev.4) (2025-10-03)

### Bug Fixes

* add newlines to debug logs ([4753873](4753873866))
2025-10-03 14:34:30 +00:00
Ax333l
4753873866 fix: add newlines to debug logs 2025-10-03 16:26:54 +02:00
8 changed files with 51 additions and 4 deletions

View File

@@ -1,3 +1,17 @@
# app [1.26.0-dev.5](https://github.com/ReVanced/revanced-manager/compare/v1.26.0-dev.4...v1.26.0-dev.5) (2025-10-03)
### Features
* Toggle to use pre-release versions of ReVanced Patches ([08cec67](https://github.com/ReVanced/revanced-manager/commit/08cec674bbbe5297090ac5ee6039569975fbe9e7))
# app [1.26.0-dev.4](https://github.com/ReVanced/revanced-manager/compare/v1.26.0-dev.3...v1.26.0-dev.4) (2025-10-03)
### Bug Fixes
* add newlines to debug logs ([4753873](https://github.com/ReVanced/revanced-manager/commit/4753873866b575e2dcb160020df63f63862c8f33))
# app [1.26.0-dev.3](https://github.com/ReVanced/revanced-manager/compare/v1.26.0-dev.2...v1.26.0-dev.3) (2025-10-03)

View File

@@ -1 +1 @@
version = 1.26.0-dev.3
version = 1.26.0-dev.5

View File

@@ -23,6 +23,7 @@ class PreferencesManager(
val managerAutoUpdates = booleanPreference("manager_auto_updates", false)
val showManagerUpdateDialogOnLaunch = booleanPreference("show_manager_update_dialog_on_launch", true)
val useManagerPrereleases = booleanPreference("manager_prereleases", false)
val usePatchesPrereleases = booleanPreference("patches_prereleases", false)
val disablePatchVersionCompatCheck = booleanPreference("disable_patch_version_compatibility_check", false)
val disableSelectionWarning = booleanPreference("disable_selection_warning", false)

View File

@@ -35,7 +35,7 @@ class ReVancedAPI(
suspend fun getLatestAppInfo() =
request<ReVancedAsset>("manager?prerelease=${prefs.useManagerPrereleases.get()}")
suspend fun getPatchesUpdate() = request<ReVancedAsset>("patches")
suspend fun getPatchesUpdate() = request<ReVancedAsset>("patches?prerelease=${prefs.usePatchesPrereleases.get()}")
suspend fun getContributors() = request<List<ReVancedGitRepository>>("contributors")

View File

@@ -45,6 +45,7 @@ import app.revanced.manager.domain.bundles.LocalPatchBundle
import app.revanced.manager.domain.bundles.PatchBundleSource
import app.revanced.manager.domain.bundles.PatchBundleSource.Extensions.asRemoteOrNull
import app.revanced.manager.domain.bundles.PatchBundleSource.Extensions.isDefault
import app.revanced.manager.domain.manager.PreferencesManager
import app.revanced.manager.domain.repository.PatchBundleRepository
import app.revanced.manager.ui.component.ColumnWithScrollbar
import app.revanced.manager.ui.component.ExceptionViewerDialog
@@ -65,12 +66,14 @@ fun BundleInformationDialog(
) {
val bundleRepo = koinInject<PatchBundleRepository>()
val networkInfo = koinInject<NetworkInfo>()
val prefs = koinInject<PreferencesManager>()
val hasNetwork = remember { networkInfo.isConnected() }
val composableScope = rememberCoroutineScope()
var viewCurrentBundlePatches by remember { mutableStateOf(false) }
val isLocal = src is LocalPatchBundle
val bundleManifestAttributes = src.patchBundle?.manifestAttributes
val (autoUpdate, endpoint) = src.asRemoteOrNull?.let { it.autoUpdate to it.endpoint } ?: (null to null)
val (autoUpdate, endpoint) = src.asRemoteOrNull?.let { it.autoUpdate to it.endpoint }
?: (null to null)
fun onAutoUpdateChange(new: Boolean) = composableScope.launch {
with(bundleRepo) {
@@ -173,6 +176,32 @@ fun BundleInformationDialog(
)
}
if (src.isDefault) {
val usePrereleases by prefs.usePatchesPrereleases.getAsState()
BundleListItem(
headlineText = stringResource(R.string.patches_prereleases),
supportingText = stringResource(R.string.patches_prereleases_description),
trailingContent = {
HapticSwitch(
checked = usePrereleases,
onCheckedChange = {
composableScope.launch {
prefs.usePatchesPrereleases.update(
it
)
}
}
)
},
modifier = Modifier.clickable {
composableScope.launch {
prefs.usePatchesPrereleases.update(!usePrereleases)
}
}
)
}
endpoint?.takeUnless { src.isDefault }?.let { url ->
var showUrlInputDialog by rememberSaveable {
mutableStateOf(false)

View File

@@ -47,7 +47,7 @@ class AdvancedSettingsViewModel(
app.contentResolver.openOutputStream(target)!!.bufferedWriter().use { writer ->
val consumer = Redirect.Consume { flow ->
flow.onEach {
writer.write(it)
writer.write("${it}\n")
}.flowOn(Dispatchers.IO).collect()
}

View File

@@ -122,6 +122,7 @@ class MainViewModel(
}
settings.usePrereleases?.let { prereleases ->
prefs.useManagerPrereleases.update(prereleases)
prefs.usePatchesPrereleases.update(prereleases)
}
settings.apiUrl?.let { api ->
prefs.api.update(api.removeSuffix("/"))

View File

@@ -437,6 +437,8 @@
<string name="auto_update">Auto update</string>
<string name="add_patches">Add patches</string>
<string name="auto_update_description">Automatically update when a new version is available</string>
<string name="patches_prereleases">Prereleases</string>
<string name="patches_prereleases_description">Use prerelease versions</string>
<string name="patches_url">Patches URL</string>
<string name="incompatible_patches_dialog">These patches are not compatible with the selected app version (%1$s).\n\nClick on the patches to see more details.</string>
<string name="incompatible_patch">Incompatible patch</string>