build: Android's built-in Kotlin, the three plugins applying KGP themselves patched in third_party/

AGP 9 compiles Kotlin itself (android.builtInKotlin=true in every app),
and warns that applying the Kotlin Gradle Plugin will soon fail.
flutter_web_auth_2 5.1.0, keyboard_height_plugin 0.3.0 and flutter_tts
4.2.5 still apply it unconditionally, so their pub releases are copied
into third_party/ with only their android/build.gradle changed, and
the root overrides them by path (third_party/README.md says when to
drop each). The servers' images copy third_party/, as pub refuses an
override whose path is missing. third_party/ isn't our own code: left
out of the analysis and the format check.

All four apps' APKs build without the warning. A Kotlin daemon's
session file that slipped into Train's android/ goes, and every app's
android/.gitignore keeps .kotlin/ out.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Tizian 「ティツィアーン」 <raisondetredev@pm.me>
This commit is contained in:
Tizian 「ティツィアーン」 2026-11-04 00:15:55 +01:00
commit 438ce20dbf
Signed by: raisondetredev
GPG key ID: 07F6FCF405488B64

View file

@ -19,10 +19,15 @@ final _written = RegExp(
r'^packages/halkyon_base_client/(lib/srp\.dart$|lib/src/srp/|test/)',
);
/// Others' plugins kept patched in the repository (`third_party/`), formatted
/// as their authors keep them.
final _others = RegExp('^third_party/');
/// Whether [path] (relative to the repository's root) is a Dart file of our
/// own, which the formatting check covers.
bool isOwnDartFile(String path) =>
path.endsWith('.dart') &&
!_others.hasMatch(path) &&
(_written.hasMatch(path) || !_generated.hasMatch(path));
/// The root's files every package's resolution or analysis depends on.