feat(v1.8.0): IMPL_06 Post-Update Changelog Dialog
- Add UpdateChangelogSheet.kt with Material 3 ModalBottomSheet
- Show changelog automatically on first launch after update
- Load changelog from F-Droid metadata via assets (single source of truth)
- Add copyChangelogsToAssets Gradle task (runs before preBuild)
- Copy F-Droid changelogs to /assets/changelogs/{locale}/ at build time
- Store last shown version in SharedPreferences (last_shown_changelog_version)
- Add ClickableText for GitHub CHANGELOG.md link (opens in browser)
- Add update_changelog_title and update_changelog_dismiss strings (EN + DE)
- Add KEY_LAST_SHOWN_CHANGELOG_VERSION constant
- Integrate UpdateChangelogSheet in ComposeMainActivity
- Add Test Mode in Debug Settings with "Reset Changelog Dialog" button
- Add SettingsViewModel.resetChangelogVersion() for testing
- Add test mode strings (debug_test_section, debug_reset_changelog, etc.)
- Update F-Droid changelogs (20.txt) with focus on key features
- Add exception logging in loadChangelog() function
- Add /app/src/main/assets/changelogs/ to .gitignore
- Dialog dismissable via button or swipe gesture
- One-time display per versionCode
Adds post-update changelog dialog with automatic F-Droid changelog reuse.
F-Droid changelogs are the single source of truth for both F-Droid metadata
and in-app display. Gradle task copies changelogs to assets at build time.
Users see localized changelog (DE/EN) based on app language.
This commit is contained in:
@@ -199,4 +199,34 @@ detekt {
|
||||
|
||||
// Parallel-Verarbeitung für schnellere Checks
|
||||
parallel = true
|
||||
}
|
||||
|
||||
// 📋 v1.8.0: Copy F-Droid changelogs to assets for post-update dialog
|
||||
// Single source of truth: F-Droid changelogs are reused in the app
|
||||
tasks.register<Copy>("copyChangelogsToAssets") {
|
||||
description = "Copies F-Droid changelogs to app assets for post-update dialog"
|
||||
|
||||
from("$rootDir/../fastlane/metadata/android") {
|
||||
include("*/changelogs/*.txt")
|
||||
}
|
||||
|
||||
into("$projectDir/src/main/assets/changelogs")
|
||||
|
||||
// Preserve directory structure: en-US/20.txt, de-DE/20.txt
|
||||
eachFile {
|
||||
val parts = relativePath.segments
|
||||
if (parts.size >= 3) {
|
||||
// parts[0] = locale (en-US, de-DE)
|
||||
// parts[1] = "changelogs"
|
||||
// parts[2] = version file (20.txt)
|
||||
relativePath = RelativePath(true, parts[0], parts[2])
|
||||
}
|
||||
}
|
||||
|
||||
includeEmptyDirs = false
|
||||
}
|
||||
|
||||
// Run before preBuild to ensure changelogs are available
|
||||
tasks.named("preBuild") {
|
||||
dependsOn("copyChangelogsToAssets")
|
||||
}
|
||||
Reference in New Issue
Block a user