Adopt library quality standard: formatting, static analysis, coverage and docs - #3
Draft
AndroidPoet wants to merge 1 commit into
Draft
Adopt library quality standard: formatting, static analysis, coverage and docs#3AndroidPoet wants to merge 1 commit into
AndroidPoet wants to merge 1 commit into
Conversation
Wire the four quality pillars into the build and align config across modules: - Spotless (ktlint 1.5.0 / ktlint_official) formats all Kotlin and Gradle scripts; shared .editorconfig drives both the IDE and the Gradle check. - detekt 1.23.7 with a shared config/detekt/detekt.yml, analysing every common/jvm/ios/wasmJs source set with per-module baselines. - Kover 0.8.3 aggregates JVM line coverage across all published modules and gates regressions via koverVerify. - Nextra documentation site under website/ (Introduction, Getting Started, Usage, Results & Errors, Modules, Platforms, Realtime) with a GitHub Pages deploy workflow. Also expands wildcard imports to satisfy ktlint, adds quality gates to the build workflow, ignores .kotlin/, and adds a Contributor Covenant code of conduct. Source reformatting is purely cosmetic; JVM compile and jvmTest pass.
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 freeto 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.
Summary
Brings the repo up to our reusable library quality standard by wiring four pillars into the build and aligning configuration across all ten published modules.
Pillars
1.5.0(ktlint_official) via the Spotless plugin8.6.0; formats Kotlin sources, all*.gradle.kts, and misc (*.md,.gitignore,config/**/*.yml). A shared.editorconfigdrives both the IDE and the Gradle check.1.23.7with a sharedconfig/detekt/detekt.yml; analyses everycommonMain/commonTest/jvmMain/iosMain/wasmJsMainsource set with per-module baselines.0.8.3aggregates JVM line coverage across all published modules;koverVerifygates regressions.website/with Appwrite-specific content (Introduction, Getting Started, Usage, Results & Errors, Modules, Platforms, Realtime) plus a GitHub Pages deploy workflow.Verification
All run locally and pass:
./gradlew spotlessApplythenspotlessCheck— clean./gradlew detekt— clean./gradlew koverXmlReport koverVerify— passes (aggregate JVM line coverage ~12.7%, floor set to 10%; most tested code lives inappwrite-core, the thin REST-wrapper service modules are currently untested)./gradlew compileKotlinJvm jvmTest— greenpnpm buildinwebsite/— all pages export to static HTMLNotable changes beyond config
no-wildcard-imports. Source reformatting is otherwise purely cosmetic.detekt.ymlwith inline rationale:MatchingDeclarationName/ktlintfilename(a file pairs anAppwrite-prefixed name with a short type whose name a sibling already owns),UnusedParameter(Kotlin/Wasmjs(...)shims reference params inside the JS string body),FunctionOnlyReturningConstant(Role/Permission constant accessors kept for API parity),MaxLineLength/TooGenericExceptionThrown(test fixtures only)..kotlin/to.gitignore, and a Contributor Covenant code of conduct.Skipped
None of the four pillars were skipped.
Notes
Draft — please review the detekt rule tunings and the coverage floor before merging.