Skip to content

Support for simple config files #49

Description

@stephenh

I have a project that using airline, and it works really well. A few of the command args are pretty short and sweet, e.g. hostname, port, but a few are potentially longer, e.g. a list of globs to whitelist/backlist files that the command processes, e.g.:

foo -h host -p port --exclude build,bin,whatever --include '*.txt,src,baz'

For just a few exclude/include args, it's not a big deal, but it seems like it would quickly become cumbersome, especially if the user invokes it on a regular basis, so I'd like to have an option to use a .foorc config file, with some sort of syntax like:

foo.exclude = build,bin,whatever
foo.include = *.txt,src,bar

Musing about what would be simplest for my program, it would be pretty awesome if airline could use the same @Option config I've setup for the CLI arg parsing to also pull in an optional config file.

Does this seem like a good idea? Or too much out of scope? If so, any hints/ideas about other ways/libraries you've seen that might do this?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementProposed Enhancement/Feature

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions