Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Re-factor argument parsing so that options shared by multiple commands aren't duplicated. #4177

Closed
tomprince opened this issue Jun 16, 2017 · 6 comments
Labels
C-cleanup Category: cleanup within the codebase

Comments

@tomprince
Copy link
Member

This might involve some clever refactoring of the docopt definitions, or it might involve porting to something like clap.

I know @matklad has looked into this.

@tomprince
Copy link
Member Author

@tomprince
Copy link
Member Author

I'm going to investigate porting things to clap.

@alexcrichton
Copy link
Member

👍

@carols10cents carols10cents added the C-cleanup Category: cleanup within the codebase label Aug 30, 2017
@matklad
Copy link
Member

matklad commented Mar 6, 2018

I'm going to make another stab at it :)

@dwijnand
Copy link
Member

dwijnand commented May 3, 2018

Fixed by #5152?

If you take the --feature option as an example you just need arg_features from command_prelude.

Look ma, no behaviour duplication!
https://github.com/search?q=repo%3Arust-lang%2Fcargo+arg_features&type=Code

@matklad
Copy link
Member

matklad commented May 3, 2018

Indeed, thanks @dwijnand

@matklad matklad closed this as completed May 3, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-cleanup Category: cleanup within the codebase
Projects
None yet
Development

No branches or pull requests

5 participants