Skip to content

[flutter_tools] Running flutter config should only show configured settings #81831

@royarg02

Description

@royarg02

Use case

Currently running flutter config also prints the usage information, which constitutes all the flags the user could pass to turn a specific feature on, thus resulting in extra noise for someone who would only want to view the currently configured settings:

$ flutter config
Configure Flutter settings.

To remove a setting, configure it to an empty string.

The Flutter tool anonymously reports feature usage statistics and basic crash reports to help improve
Flutter tools over time. See Google's privacy policy: https://www.google.com/intl/en/policies/privacy/

Global options:
-h, --help                  Print this usage information.
-v, --verbose               Noisy logging, including all shell commands executed.
...

The (new) user would have to scan this message all the way down to view the settings, or worse, might completely miss them.

Proposal

Since the usage information can be also viewed by passing -h/--help just like other flutter sub-commands, flutter config could be configured to only show the current user settings, with a suggestion to run flutter config -h to view all settings.

$ flutter config
Configured Flutter settings.
Run "flutter config -h" to see all available settings.

  enable-linux-desktop: true
  enable-web: true
  enable-ios: false

Analytics reporting is currently disabled.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3Issues that are less important to the Flutter projectc: new featureNothing broken; request for a new capabilityc: proposalA detailed proposal for a change to Flutterr: fixedIssue is closed as already fixed in a newer versionteam-toolOwned by Flutter Tool teamtoolAffects the "flutter" command-line tool. See also t: labels.triaged-toolTriaged by Flutter Tool team

    Type

    No type

    Projects

    Status

    Engineer reviewed

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions