Repository navigation
ADFA-174: Rename packages to org.appdevforall.codeonthego (Phase 2) - #2136
Draft
jimturner-adfa wants to merge 11 commits into
Draft
jimturner-adfa wants to merge 11 commits into
jimturner-adfa wants to merge 11 commits into
Conversation
…l.codeonthego) Phase 1 of the rename plan: record the decision to reverse ADR 0008 and rename the application id / namespace, instead of silently editing the original decision. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
…l.codeonthego.annotations Phase 2 pilot slice: the `annotations` module and every file that references it (annotation-processors, annotation-processors-ksp, uidesigner, xml-inflater). Package declarations, imports, KDoc links, the FQN annotation usage, and the KSP service-provider descriptor all moved together. Does not touch BuildConfig.PACKAGE_NAME, applicationId, or AGP namespace - those stay com.itsaky.androidide until Phase 3 (ADR 0017), which is gated on the terminal-packages cross-repo coordination. Verified: :annotations, :annotation-processors, :annotation-processors-ksp, :uidesigner, :xml-inflater compile, and xml-inflater/uidesigner unit tests (which exercise the ViewAdapter/ IncludeInDesigner path end-to-end through KSP) pass. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
…devforall.codeonthego Renames Kotlin/Java package declarations, directory layout, manifest strings, and build-script references across the tree. Does not touch BuildConfig.PACKAGE_NAME, applicationId, or AGP namespace - those stay com.itsaky.androidide until Phase 3 (ADR 0017), which is gated on the terminal-packages cross-repo coordination tracked in ADFA-6386. Deliberately left at the old namespace, since each is tied to that same deferred constant or an external identity: - Generated classes (R, BuildConfig, the per-module eventbus index classes, data-binding Binding classes) - these live wherever AGP's namespace currently points, which hasn't moved. - composite-builds/ (vendored build-logic, ADR 0003) and the :gradle-plugin module (its generated init-script string is a literal FQN baked in by composite-builds). - The vendored fork packages inside composite-builds/build-deps (desugaring, diffutils, fuzzysearch, javac.config, layoutlib, zipfs2) and the external android-tree-sitter library (com.itsaky.androidide.treesitter). - Cross-app identity checks: Firebase's google-services.json, logsender's and termux's manifest <package> references, and the literal applicationId strings in tests/docs that describe the currently-running app. - testing/resources/sample-project and gradle-plugin/src/test/resources (fixtures simulating an external project, not our own identity). :plugin-api/:plugin-manager (com.itsaky.androidide.plugins.*) are included in this pass per team decision, despite being a published surface for third-party IDE plugins - plugin-builder's own group was already migrated to org.appdevforall.codeonthego.plugins before this branch existed. One real bug fixed along the way: common's FileProviderUtilsTest had a test fixture whose expected-output literal was swept along with production code, even though the test's whole point is exercising today's real (unflipped) package name as input. Verified: a full-tree compile (every module, every flavor/build-type, including a sweep for bare R/BuildConfig/databinding usage in files sitting at a module's namespace root) is clean, and the full unit test suite is green except a pre-existing lsp:java `refactor` test family (ExtractMethodPlanTest, ExtractMethodEditTest, ExtractVariableSoundnessTest, RegionAnalysisPrimitivesTest, ExtractMethodSignatureTest, ExtractionRegionSoundnessTest) - confirmed by stashing this entire change and re-running against the untouched baseline: identical failures, unrelated to this rename. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Conflicts were all rename-vs-edit. Resolved by taking stage's version
of each file and reapplying the Phase 2 mechanical rename (same keep
rules: R, BuildConfig, databinding, treesitter, vendored forks, eventbus
indexes, build-logic). The scripted rename reproduces the original
Phase 2 commit for 2451 of 2516 renamed Kotlin/Java files; the misses
are string literals and :gradle-plugin, none of which were touched here.
- 41 files stage added under com/itsaky/androidide (memprof, terminal,
new tests) moved to org/appdevforall/codeonthego and renamed.
- Stage-side imports of old FQNs in cleanly merged files renamed
(jvm-symbol-index, termux clients, profileable manifest).
- ProjectManagerImpl keeps the explicit com.itsaky.androidide.projects.R
import added in Phase 2.
- BuildInProgressException deleted, as on stage.
Verified with unit-test compiles of app, lsp/{java,kotlin,xml,
jvm-symbol-index}, plugin-manager, projects, shared, javac-services,
tooling-api-impl, termux-app, and the app's profileable variant.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The Phase 2 rename touched ~2,700 files, pulling each under the file-level spotless ratchet. This applies spotlessApply to them as-is. Compiles cleanly (main + unit-test sources, all modules). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The rename pulled ~2,700 files under the spotless ratchet; 50 of them had pre-existing ktlint errors that block spotlessApply. No behaviour change. - Naming rules (backing-property, property, function naming): @Suppress per the existing repo convention, rather than renaming public/internal API. - Wildcard imports expanded; mixed &&/|| parenthesised; comments moved off code lines or out of if/else and import lists; duplicate license header removed; orphan KDoc in IdeTooltipService removed; empty EditorRightSidebarActions.kt deleted. - 10 files get @file:Suppress("ktlint:standard:max-line-length"): ktlint measures tab-indented input short, joins lines, then fails the 140 limit on its own output (same formatter interaction noted in OfflineGuard.kt). - Re-indents files the previous commit left flat: spotless converted their 2-space indent to tabs even though ktlint had bailed on them. spotlessCheck passes; main + unit-test sources compile for all modules. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Relative android:name values (".app.IDEApplication") resolve against
the module namespace, which stays com.itsaky.androidide until Phase 3.
After the package rename they pointed at classes that no longer exist,
so the app could not start: 565 :app Robolectric tests failed with
ClassNotFoundException for com.itsaky.androidide.app.IDEApplication.
Fully qualified names hold regardless of namespace, so Phase 3 does not
need to touch them. 30 entries across 7 manifests (app main/debug/
androidTest, floating-window, logsender, logsender-sample, uidesigner).
Swept layouts, ProGuard rules, META-INF/services and other manifest
attributes for old FQNs of moved classes; none found.
:app:testV8DebugUnitTest: 1461 tests, 0 failures (was 566).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
AndroidModuleConf still named com.itsaky.androidide.testing.android. TestInstrumentationRunner, which the Phase 2 rename moved to org.appdevforall.codeonthego.testing.android, so instrumentation tests could not start. Checked the other quoted class names in composite-builds and gradle-plugin; this was the only stale one. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
plugin-api.api still described the classes under com/itsaky/androidide, which the Phase 2 rename moved, so :plugin-api:apiCheck (run by the debug workflow) failed. Its BuildConfig exclusion also still named the old package, so the regenerated dump would have published the generated BuildConfig as API; point it at org.appdevforall.codeonthego.plugins.api.BuildConfig. The new dump has the same declarations as the old one with the package renamed; one method's position changes with the new sort order. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The Phase 2 rename moved com/itsaky/androidide/... source directories to org/appdevforall/codeonthego/..., but 84 path references in the quickbuild docs, PLUGIN_AUTHORING.md, ARCHITECTURE.md and ADR 0015 still named the old locations. Each was rewritten only where the new path exists and the old one does not. Dated plans/specs under docs/superpowers are left as written. ExtractZipToDirMergeTest's sample plugin-api entry now uses the org/appdevforall/codeonthego Maven layout the shipped repo uses. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A grep example still pointed at app/src/main/java/com/itsaky/androidide, which the Phase 2 rename moved; the earlier sweep only matched paths with a trailing slash. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Collaborator
|
Filed ADFA-6791 (subtask of ADFA-174): migrate the appdevforall/addons repo in lockstep with this PR's package and Gradle plugin id rename. |
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.
ADFA-174
Important
Merge together with the terminal change. This must land at the same time as the matching change in appdevforall/terminal-packages#3 (ADFA-6386). The terminal bootstrap packages have the package name baked in, so the two cannot ship independently - see ADR 0017.
Renames the Kotlin/Java packages and source directories from
com.itsaky.androididetoorg.appdevforall.codeonthego(Phase 2 of ADR 0017).Scope
Not changed - these stay
com.itsaky.androidideuntil the identity flip (Phase 3):BuildConfig.PACKAGE_NAME,applicationId, the AGP namespace, and the provider authority.R,BuildConfig, data-binding, and the eventbus index classes.composite-builds/(ADR 0003),:gradle-plugin, android-tree-sitter.Review by commit
76bea7d8b6ecf001acf6c382770a0cdedab0stage; stage's new and edited files get the same rename206059696spotlessApplyon every file the rename pulled under the ratchet - formatting onlyb9e6916dc6666c88786179a5fb9testInstrumentationRunnerat the renamed class - instrumentation tests could not startb9a9050c0plugin-api.apifor the moved packages -:plugin-api:apiCheck(run bydebug.yml) failed0d28ff3e58c0549f3equickbuild/docs/debugging.mdNotes for reviewers:
6179a5fb9:AndroidModuleConfstill namedcom.itsaky.androidide.testing.android.TestInstrumentationRunner, whichf6c382770moved. The merged test manifest now namesorg.appdevforall.codeonthego.testing.android.TestInstrumentationRunner. A sweep of the other quoted class names incomposite-buildsandgradle-pluginfound no other stale one.b9a9050c0: the API dump still listedcom/itsaky/androidide/plugins/.... The regenerated dump has the same declarations with the package renamed; one method's position changes with the sort order. TheBuildConfigexclusion inplugin-api/build.gradle.ktsalso named the old package, which would have published the generated class as API.0d28ff3e5,8c0549f3e: each path was rewritten only where the new location exists and the old one doesn't. Dated plans and specs underdocs/superpowersare left as written.6666c8878: relative manifest names like.app.IDEApplicationresolve against the namespace, which stayscom.itsaky.androidideuntil Phase 3. Afterf6c382770they pointed at classes that no longer existed, so the app couldn't start. This commit writes out 30 entries across 7 manifests in full; those names work under either namespace. A sweep found no other text references (layouts, ProGuard rules,META-INF/services, other manifest attributes) to moved classes.a0cdedab0: each conflict was resolved by re-running the rename on stage's version of the file. The scripted rename reproducesf6c382770exactly for 2,451 of its 2,516 renamed Kotlin/Java files; the rest are string literals and:gradle-plugin, none of which the merge touched.206059696: about 45 files that used 2-space indentation come out flat in this commit.b9e6916dcre-indents them.b9e6916dc: naming-rule violations are suppressed, following the repo's existing@Suppressconvention, rather than renamed. Ten files carry@file:Suppress("ktlint:standard:max-line-length")for the same tab-measurement problem documented inOfflineGuard.kt.Verification
spotlessCheckand:plugin-api:apiCheckpass.testV8DebugUnitTestin every module,:plugin-api:testDebugUnitTest, andtestin the 7 JVM modules - 6,046 tests.6666c8878: 566:apptests failed, all from the manifest bug.:app:testV8DebugUnitTest: 1,461 tests, 0 failures. The full sweep has not been re-run since the fix.lsp/kotlinGoToDefinitionTestfailed once in the full sweep and passes on its own, so it depends on test order rather than on this change.:gradle-plugintests were not run. The rename deliberately didn't touch that module.:app:assembleV8Debugon a Pixel 6 Pro (arm64-v8a, API 37). The app launches to onboarding; the front screen iscom.itsaky.androidide/org.appdevforall.codeonthego.activities.OnboardingActivity, and logcat shows no crash orClassNotFoundException. As intended for Phase 2, the app ID and data directory staycom.itsaky.androidide. Setup past the Permissions screen was not exercised.6179a5fb9).Phase 3 (the application id / namespace flip) is stacked on this branch as #2179.
🤖 Generated with Claude Code