Adapt AGENTS.md for CMP needs - #3461
Conversation
| Most often, we work in `./compose/ui/ui` and `./compose/foundation/foundation`. | ||
| Also, we publish klibs for some other libraries: `./navigation`, `./navigation3`. | ||
|
|
||
| In this fork, we apply fork-specific gradle files: `./gradle/libs-fork.versions.toml`, and `build-fork.gradle` in the modules, which co-exist with the upstream gradle files. |
There was a problem hiding this comment.
| In this fork, we apply fork-specific gradle files: `./gradle/libs-fork.versions.toml`, and `build-fork.gradle` in the modules, which co-exist with the upstream gradle files. | |
| The repo contains both the original AOSP code and additional fork-only code. | |
| The repo supports two modes: the original AOSP mode (`aospComposeProject.sh`), with the original set of modules, and fork mode, with a much smaller set of modules and its own build infrastructure. Fork mode is the primary mode and is used by default; AOSP mode is rarely needed. | |
| - Common code, used by both modes: | |
| - `commonMain`, `commonTest`, and other source sets defined both in `build.gradle` and `build-fork.gradle` files | |
| - Received from the upstream AOSP repo | |
| - Fork-only code: | |
| - Independent build infrastructure: `settings-fork.gradle`, `buildSrc-fork`, `build-fork.gradle`, and `./gradle/libs-fork.versions.toml` | |
| - if modules exists only in `settings-fork.gradle`, but not in `settings.gradle`, it may just contain `build.gradle` without `build-fork.gradle` | |
| - iOS, desktop, JS, and WasmJS source sets, their combinations, and their corresponding test source sets | |
| - AOSP-only code: | |
| - Independent build infrastructure: `settings.gradle`, `buildSrc`, `build.gradle`, and `./gradle/libs.versions.toml` | |
| - `androidMain` and its corresponding test source sets | |
| - `*StubsMain` source sets - created in the upstream AOSP repo to ensure `commonMain` compilation on the all Kotlin targets | |
| - iOS, desktop, JS, and WasmJS source sets for libraries and targets developed in AOSP |
There was a problem hiding this comment.
I applied your suggstion. But have a question.
Fork mode is the primary mode and is used by default; AOSP mode is rarely needed.
Is it worth to add it in AGENTS.md instructions if most of the time we work in the fork mode, making AOSP-only details irrelevant?
Also about redirects - most of the times, when itroducing changes / making fixes in the fork we don't bother with redicrects. I believe this information might be a noise for the agents in most cases. WDYT?
There was a problem hiding this comment.
I think this worth it. If we don't mention different modes, the files are not differentiated. Adding "AOSP mode is rarely needed" we say that associated with it files should be not touched in most cases.
There was a problem hiding this comment.
Also about redirects
Probably, let's remove lines redirectversions.toml, libraryversions.toml
There was a problem hiding this comment.
Probably, let's remove lines redirectversions.toml, libraryversions.toml
Fixed.
Adding "AOSP mode is rarely needed" we say that associated with it files should be not touched in most cases.
Such an instruction is quite vague - it might make the agent wonder if/when it's applicable - Is the "rarely needed" applicable for the particular case?
But the models improve, and I'm fine to try it and see how it goes.
Co-authored-by: Igor Demin <igordmn@users.noreply.github.com>
Co-authored-by: Igor Demin <igordmn@users.noreply.github.com>
Co-authored-by: Igor Demin <igordmn@users.noreply.github.com>
Co-authored-by: Igor Demin <igordmn@users.noreply.github.com>
Co-authored-by: Igor Demin <igordmn@users.noreply.github.com>
Co-authored-by: Igor Demin <igordmn@users.noreply.github.com>
Release Notes
N/A