Skip to content

Give the git and projects features matching package roots - #86

Merged
AhmadKharfan merged 1 commit into
developfrom
refactor/git-feature-package
Jul 30, 2026
Merged

Give the git and projects features matching package roots#86
AhmadKharfan merged 1 commit into
developfrom
refactor/git-feature-package

Conversation

@AhmadKharfan

Copy link
Copy Markdown
Owner

Why

Two feature modules had package roots that did not name them, which the earlier dependency audit repeatedly tripped over:

  • :feature:git declared feature.editor.git.* — its code lived under the editor's namespace, so a search for git symbols found editor-shaped names and vice versa
  • :feature:projects declared feature.hub, feature.createproject, feature.openproject, feature.clonerepo, feature.folderpicker — no projects segment at all

When a module's package does not say which module owns it, no import-based reasoning is reliable. That already produced a wrong answer once during the stale-dependency audit.

The contract modules also inherited public by default, which is the wrong default for a module whose entire purpose is a reviewable surface.

What changed

  • feature.editor.git.*feature.git.* (52 files)
  • feature.{hub,createproject,openproject,clonerepo,folderpicker}feature.projects.{…} (30 files)
  • explicitApi() on :feature:git:api and :feature:buildrun:api, with every declaration now stating its visibility

Every package root in the repo now belongs to exactly one Gradle module, and each feature module's package names it.

Behavior

No behavior change. Package declarations, imports, and visibility modifiers that were already implicit.

Tests

  • 723 tests passing, 0 failures.

Verification

./gradlew test detekt verifyModuleBoundaries :app:assembleDebug — BUILD SUCCESSFUL. Boundary report: 0 baseline entries, 0 violations.

Verified on an emulator, since a package rename is exactly the kind of change that compiles and then fails to resolve a resource or a reflective lookup at runtime:

  • App launches, project opens, editor renders
  • The git panel opens and renders "Git · HEAD" with its empty state
  • No Resources$NotFoundException, AbstractMethodError or NoClassDefFoundError in logcat

Note on the detekt baselines: adding explicit public modifiers changes the signature strings that key baseline entries, so the two entries in :feature:git:api were re-keyed rather than regenerated. Nothing new is absorbed.

@AhmadKharfan
AhmadKharfan merged commit cd4883e into develop Jul 30, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant