-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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-order optional arguments in usage strings to appear before required arguments #147
Comments
Sorry I wanted to say that I got this line (Didn't know I have to escape < and >) |
I'm in the process of updating the videos now actually :) There have been some significant changes/improvements since those were made. As for your question though, yes and no. "No" because it works either way; as the optional flags and optional options could go before or after the required arguments and work just fine. If you need to change the usage string (to match documentation or anything), you can use Hope this answers your question :) If not, feel free to contact me! Edit: And thanks for watching the videos and taking the time to comment!! 👍 |
Yes, I know that it works either way. I only think it is more 'natural' to have flags and options coming first. IIRC, then in the samples you presented in the videos it came out more naturally like this: |
I think you're correct as well. If I get some time this weekend I'll take a look at some possible ways to re-order them back to the expected way. I've got some ideas on how to do so, I just need to test them :) |
Sounds great. Thx a lot. |
…dard Also renamed is '[POSITIONAL]' => '[ARGS]' to use the more standard vernacular Closes #147
Turned out to be way easier than I imagined, so I've just put in a PR to correct this to the more standard natural order. I've also change Once Travis passes I'll merge this into master and upload Thanks again for taking the time to file this! |
1.0.2 on crates.io or master here is good to go now! Once I finish these updated videos everything should be back in sync ;) |
Just tested. Works fine. |
Hi Kevin,
First of all, your videos are really great. Thanks for this.
Question: I played with fake and when invokind fake like this:
./target/debug/fake --help
one of the lines is this:
fake [FLAGS] [OPTIONS]
Shouldn't it be the other way round?
fake [FLAGS] [OPTIONS]
-- Manfred
The text was updated successfully, but these errors were encountered: