This repository has been archived by the owner. It is now read-only.

Advanced cli args specification in yaml #26

Open
bkabrda opened this Issue Mar 6, 2013 · 4 comments

Comments

Projects
None yet
3 participants
@bkabrda
Member

bkabrda commented Mar 6, 2013

Yaml assistants should have a way of specifying that one parameter is not mandatory when another one is present (e.g. at least one of a group must be used).

@ghost ghost assigned bkabrda Mar 6, 2013

@zaufi

This comment has been minimized.

Show comment Hide comment
@zaufi

zaufi Dec 9, 2013

Contributor

also it would be nice to have:

  • predictable order of options between runs -- i.e. if I execute da crt some -h I see different output from run to run...

  • ability to specify an argument name -- i.e. nowadays argument option is named after a flag name but uppercased... it would be neat to change it! For example instead of this

    -t [UNIT_TESTS], --unit-tests [UNIT_TESTS]
                            Add support for unit tests Argument is
                            a framework/library name: cppunit, boost, Qt, gtest
    

    I want this

    -t [NAME], --unit-tests [NAME]
                            Add support for unit tests Argument is
                            a framework/library name: cppunit, boost, Qt, gtest
    
  • options grouping

Contributor

zaufi commented Dec 9, 2013

also it would be nice to have:

  • predictable order of options between runs -- i.e. if I execute da crt some -h I see different output from run to run...

  • ability to specify an argument name -- i.e. nowadays argument option is named after a flag name but uppercased... it would be neat to change it! For example instead of this

    -t [UNIT_TESTS], --unit-tests [UNIT_TESTS]
                            Add support for unit tests Argument is
                            a framework/library name: cppunit, boost, Qt, gtest
    

    I want this

    -t [NAME], --unit-tests [NAME]
                            Add support for unit tests Argument is
                            a framework/library name: cppunit, boost, Qt, gtest
    
  • options grouping

@bkabrda

This comment has been minimized.

Show comment Hide comment
@bkabrda

bkabrda Dec 9, 2013

Member
  • The order of the arguments is implementation detail of argparse, AFAICS. But you're right, it'd be nice to have a predictable order. If I have some time I'll look into this and try to send a patch upstream.
  • You can do it like this:
  args:
    foo:
      flags: [-f]
      metavar: FOO # this is what you're looking for... I'll document it when I have some time
      help: Foo bar
  • Yeah, options grouping is another nice TODO :)
Member

bkabrda commented Dec 9, 2013

  • The order of the arguments is implementation detail of argparse, AFAICS. But you're right, it'd be nice to have a predictable order. If I have some time I'll look into this and try to send a patch upstream.
  • You can do it like this:
  args:
    foo:
      flags: [-f]
      metavar: FOO # this is what you're looking for... I'll document it when I have some time
      help: Foo bar
  • Yeah, options grouping is another nice TODO :)

@tradej tradej added this to the 0.10.0 milestone Jun 19, 2014

@tradej

This comment has been minimized.

Show comment Hide comment
@tradej

tradej Oct 3, 2014

Member

An example of the problem outlined in the issue is prep/custom's $url vs $gh_repo. When one of them is specified, the other is either redundant or outright forbidden.

Member

tradej commented Oct 3, 2014

An example of the problem outlined in the issue is prep/custom's $url vs $gh_repo. When one of them is specified, the other is either redundant or outright forbidden.

@tradej

This comment has been minimized.

Show comment Hide comment
@tradej

tradej Nov 4, 2014

Member

This bug is dependent on the new GUI implementation, so we can not make it to 0.10.0.

Member

tradej commented Nov 4, 2014

This bug is dependent on the new GUI implementation, so we can not make it to 0.10.0.

@tradej tradej removed this from the 0.10.0 milestone Nov 4, 2014

@bkabrda bkabrda added this to the 1.0 milestone Nov 14, 2014

@bkabrda bkabrda modified the milestones: 0.11, 1.0 Feb 12, 2015

@bkabrda bkabrda removed this from the 0.11 milestone Mar 19, 2015

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