Skip to content

No good way to create a 'Parsed' object #16

@floitsch

Description

@floitsch

It's currently common to call a method with the Parsed object:

  --run=:: foo it


foo parsed/cli.Parsed:
  ...

If I wanted to call the foo function directly, then I would need to create a Parsed object myself. That's currently not really possible.

We should either make this possible, or discourage passing the Parsed object around.

For example, we could encourage to always extract the options in the lambda:

  --run=:: foo it["option1"] it["option2"] ...

That could get messy, and would go against future API plans, where we would like to give a Cli object that has ui, config, and cache (in addition to parsed). That said, maybe parsed shouldn't be part of that object.

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