Skip to content

config printing enhancements #6256

@calebcartwright

Description

@calebcartwright

rustfmt currently provides the ability to print configuration details in various forms:

  • default (documented briefly here) which dumps the full set of configuration options with their default values, regardless any existing detected or specified configuration inputs
  • current - dumps the configuration incorporating specified and detected values (e.g. any additionally included command line flags, detected configuration files, etc.)
  • minimal - the subset of the configurations from current that are actively utilized when formatting some specified input code/file (the primary use case for this is to help users locate unused/inoperable options and to be able to remove them from their rustfmt config file)

in #6247 there was some discussion about potential enhancements to this current configuration printing feature, and I'd suggest there's two potential (non mutually exclusive) items we could consider:

  • show the full set of configuration options with the default values based on the specified style edition
  • show the subset of configuration options that changed for a specified style edition

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-configArea: configurationC-enhancementCategory: an enhancement proposalSO-print-configStable option: `--print-config`

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions