Skip to content

Support -D (or other) shorthand for --dart-define #98593

@SpencerC

Description

@SpencerC

Use case

Per flutter/flutter-intellij#5952 (comment), enable shorthand for the --dart-define command line arguement.

Proposal

Per the dart documentation:

dart run -h
...
-D, --define=<key=value>                               Define an environment declaration.

mirror this behavior in Flutter:

flutter run -h
...
-D, --dart-define=<foo=bar>                       Additional key-value pairs that will be available as constants from the String.fromEnvironment, bool.fromEnvironment, int.fromEnvironment, and double.fromEnvironment constructors.

Metadata

Metadata

Assignees

Labels

P3Issues that are less important to the Flutter projectc: new featureNothing broken; request for a new capabilityteam-toolOwned by Flutter Tool teamtoolAffects the "flutter" command-line tool. See also t: labels.tool-still-validIssues that have been deemed still valid as part of the Flutter Tools issue cleanup initiative.triaged-toolTriaged by Flutter Tool team

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions