Skip to content

Conversation

@davidmorgan
Copy link
Contributor

Reduce the generated code to a minimum: just a map from builder name to builder factory, and another map from post process builder name to post process builder factory.

There used to be configuration from yaml files hard coded in the generated script, compute it at runtime instead.

This means

  • fewer changes to the script / fewer needs to restart and rebuild
  • tests can load the config instead of faking it

but for now don't change restart functionality or tests, keep everything as before.

@github-actions
Copy link

PR Health

Changelog Entry
Package Changed Files
package:build_runner build_runner/bin/build_runner.dart
build_runner/lib/build_runner.dart
build_runner/lib/src/bootstrap/build_script_generate.dart
build_runner/lib/src/build_plan/apply_builders.dart
build_runner/lib/src/build_plan/build_plan.dart
build_runner/lib/src/build_plan/builder_factories.dart
build_runner/lib/src/build_plan/builder_ordering.dart
build_runner/lib/src/build_plan/testing_overrides.dart
build_runner/lib/src/build_runner.dart
build_runner/lib/src/commands/build_command.dart
build_runner/lib/src/commands/daemon_command.dart
build_runner/lib/src/commands/run_command.dart
build_runner/lib/src/commands/serve_command.dart
build_runner/lib/src/commands/test_command.dart
build_runner/lib/src/commands/watch_command.dart
build_runner/lib/src/internal.dart
package:build_test build_test/lib/src/test_builder.dart

Changes to files need to be accounted for in their respective changelogs.

This check can be disabled by tagging the PR with skip-changelog-check.

@davidmorgan davidmorgan changed the title Less build script Minimize generated code Sep 17, 2025
@davidmorgan davidmorgan changed the title Minimize generated code Reduce generated code Sep 17, 2025
@davidmorgan davidmorgan marked this pull request as ready for review September 17, 2025 08:53
@davidmorgan davidmorgan merged commit bc04cab into dart-lang:master Sep 17, 2025
61 of 64 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants