Skip to content

Add YAML config (--config) for shorter command #47

@mochi-yu

Description

@mochi-yu

Background

I run deep-copy from //go:generate. The whole command has to be one line—I cannot break it across lines. As I add more types and flags, that line gets very long. My diffs get noisy and I run into merge conflicts more often.

Idea

I want a YAML config file with the same options I already pass as flags.

  • I would pass it with --config path/to/file.yaml.
  • If I also set a flag on the command line, the flag should win over the file.

Then I can keep go:generate short, e.g. deep-copy --config deep-copy.yaml ., and put real changes in the YAML file.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions