ci: Update Dokka configuration and unify AboutLibraries JSON generation#4767
Merged
jamesarich merged 3 commits intomainfrom Mar 13, 2026
Merged
ci: Update Dokka configuration and unify AboutLibraries JSON generation#4767jamesarich merged 3 commits intomainfrom
jamesarich merged 3 commits intomainfrom
Conversation
This commit updates the build logic for Dokka documentation generation to include additional Kotlin Multiplatform (KMP) source sets. Specific changes include: - Added `jvmMain` and `jvmAndroidMain` to the list of source sets processed by Dokka in `Dokka.kt`. Signed-off-by: James Rich <2199651+jamesarich@users.noreply.github.com>
This commit refactors the AboutLibraries configuration to unify library license generation across Android and Desktop platforms. The manual `AboutLibrariesJsonProvider` utility has been replaced by the standard `exportLibraryDefinitions` Gradle task, which now outputs the required JSON directly to resources.
Specific changes include:
- **Build Configuration**: Updated `aboutlibraries` plugin to use the base multiplatform-compatible version and applied it globally.
- **Dependency Management**: Added `aboutlibraries-core` and `aboutlibraries-compose-m3` to `core:common` and the `desktop` module to support license rendering in shared UI.
- **Automation**: Updated `app/build.gradle.kts` to export the library definitions to `src/main/resources/aboutlibraries.json` and added this generated file to `.gitignore`.
- **CI/CD**: Added the `exportLibraryDefinitions` task to the release workflow to ensure license data is updated during automated builds.
- **Refactoring**:
- Deleted `AboutLibrariesJsonProvider.kt` in favor of direct resource loading via the classpath.
- Updated `SettingsNavigation.kt` (Android) and `DesktopSettingsNavigation.kt` (Desktop) to load the JSON resource using standard Java resource fetching.
Signed-off-by: James Rich <2199651+jamesarich@users.noreply.github.com>
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #4767 +/- ##
=======================================
Coverage 12.17% 12.18%
=======================================
Files 531 530 -1
Lines 17726 17714 -12
Branches 2647 2646 -1
=======================================
Hits 2158 2158
+ Misses 15255 15243 -12
Partials 313 313 ☔ View full report in Codecov by Sentry. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces improvements to how the AboutLibraries JSON data is generated, exported, and loaded for both Android and desktop platforms. It streamlines the process by exporting the JSON file directly during the build, removes redundant provider code, and ensures consistent loading of library license information in the app. Additionally, it updates build logic to support Compose Desktop applications and refines dependency management.
Enhancements to AboutLibraries JSON export and loading:
src/main/resources/aboutlibraries.jsonduring the build process, ensuring consistent access for both Android and desktop platforms. (app/build.gradle.kts, app/build.gradle.ktsL340-R343).github/workflows/release.yml, [1] [2] [3]AboutLibrariesJsonProviderclass was removed, and JSON loading in navigation code was simplified to directly read from the classpath resource. (app/src/main/kotlin/org/meshtastic/app/util/AboutLibrariesJsonProvider.kt, [1];app/src/main/kotlin/org/meshtastic/app/navigation/SettingsNavigation.kt, [2] [3];desktop/src/main/kotlin/org/meshtastic/desktop/navigation/DesktopSettingsNavigation.kt, [4]Build logic and dependency updates:
core/common/build.gradle.kts, [1];desktop/build.gradle.kts, [2] [3]build-logic/convention/src/main/kotlin/org/meshtastic/buildlogic/Dokka.kt, build-logic/convention/src/main/kotlin/org/meshtastic/buildlogic/Dokka.ktR45-R46)Support for Compose Desktop applications in build logic:
build-logic/convention/src/main/kotlin/org/meshtastic/buildlogic/Graph.kt, [1] [2]