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

Support multiple positionals #97

Merged
merged 4 commits into from
Jun 15, 2023

Conversation

aherrmann
Copy link
Contributor

Add support for multiple positional parameters - display such parameters correctly in the help and usage messages.
Adds unit tests for the help and usage message.

@Hejsil
Copy link
Owner

Hejsil commented Jun 15, 2023

I'll merge this, as it is an improvement for help and usage. Do note though, that parse will not handle this correctly in certain cases. For example <u32> <string>... will make the positionals field in the result be []const u32, ignoring that the other positional parameter specified string.

@Hejsil Hejsil merged commit 988375a into Hejsil:master Jun 15, 2023
@aherrmann aherrmann deleted the upstream-multiple-positionals branch June 16, 2023 06:14
@aherrmann
Copy link
Contributor Author

@Hejsil thank you! And thanks for pointing out the current limitations. My current use-case only involves string parameters, so I didn't notice this limitation. I've opened #98 to keep track of this limitation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants