Skip to content

0.0.15

Choose a tag to compare

@github-actions github-actions released this 12 Sep 21:24
· 11 commits to master since this release
57edb4a

Added

  • XcodeProjectEditor.setEntitlementsPaths(path, {'Release': '...'}), the per-configuration twin of setEntitlementsPath. The existing setter writes one CODE_SIGN_ENTITLEMENTS value to every build configuration of the application target, which is right for every entitlement but one: Apple makes aps-environment a property of the BUILD, so a development provisioning profile carries development and a distribution one carries production, and one file cannot satisfy both. A plugin that installs push therefore had no way to leave a project able to archive, and magic_notifications defers the distribution value in a comment for exactly this reason. Configurations the map does not name are left untouched, so a caller can repoint Release without touching Debug, and everything that makes the original safe is shared rather than duplicated: the byte-for-byte round-trip guard, the application-target scoping that keeps the test bundle and the project defaults clean, the no-repointing rule and the staged write. The old entry point is now that shared body with a resolver answering the same path for every configuration, so the two cannot drift.

    Two refusals, because the return type has no channel for either. An EMPTY map throws ArgumentError: a silent no-op is indistinguishable from a successful write. A map naming configurations the project does not have throws StateError, which is the same "nothing will be written" condition one step later and the one a Flutter flavour produces by default, since its configurations are Release-production and Release-staging and asking for Release matches nothing. A PARTIAL miss stays quiet and writes what it can.

  • start --flutter-arg=<arg>, repeatable, forwards an argument verbatim to flutter run. start assembled its argv from a fixed literal, so a caller who needed --dart-define, --flavor, --web-renderer or any other flutter run flag had no way to ask for it, and the only workaround was to stop using start and lose the session record with it: state.json is what gives stop, status, hot-restart and every MCP tool something to act on, and nothing else writes it. Reported from a consumer that wanted a compile-time define to switch a fixture size for a performance run and had to move the switch onto a URL query parameter instead. The values land after the arguments start builds, so a repeated flag overrides the default it chose (flutter run takes the last occurrence), they are recorded in state.json as flutterArgs, and restart replays them. restart declares the same flag, so an explicit one wins over the carried set exactly as --device and the ports already do. The comma split args applies to a multi-option by default is switched off: it is the wrong shape for a passthrough and it broke the exact case the flag exists for, turning --flutter-arg=--dart-define=TAGS=a,b into two tokens so that flutter run read the bare b as a positional target. Carrying them matters more than carrying a port: a dropped port refuses to bind and says so, while a dropped define compiles clean and the app behaves differently.

Changed

  • _buildSettingsOf now throws when a build configuration carries no name. It has to read the name to let a caller address one configuration, and a configuration nothing can address is a project this should report rather than quietly halve. InstallTransaction._pointXcodeAtEntitlements already catches StateError and degrades to a warning, so an install skips the setting rather than aborting.

  • The two flutter run argv literals became one function. The plain branch and the --cdp-port branch each built the list from their own copy, so a flag added to one silently did not reach the other. StartCommand.flutterArgsFor is now the single builder and is pure, which is what lets the argv be asserted without spawning a real flutter run, the same reason bootingState is exposed.