Skip to content

Conversation

@peteanning
Copy link
Contributor

cargo download 01 --year 2021 Compiling pico-args v0.5.0 Compiling aoc v0.6.2 (/Users/peter/projects/sandbox/tmp/advent-of-code-rust) Finished dev [unoptimized + debuginfo] target(s) in 1.59s Running `target/debug/download 01 --year 2021` Downloading input via aoc-cli... error: Found argument '--file' which wasn't expected, or isn't valid in this context 

Reading the docs the options come before the command.

This change puts the command after the options and for me now works?

@fspoettel
Copy link
Owner

fspoettel commented Nov 6, 2022

Strange, this works for me on all OS I have access to (macOS 12, windows 10, ubuntu 20.04). What OS are you seeing this on?

Looking at the docs, your change looks good, so it definitely makes sense to merge either way.

@fspoettel
Copy link
Owner

fspoettel commented Nov 6, 2022

This broke between aoc-cli@0.3.0 and aoc-cli@0.4.0 released yesterday - their old arg parser did not enforce the documented argument order.

@fspoettel
Copy link
Owner

@peteanning Thank you for reporting the regression with the new aoc-cli version and the prompt fix! 😊

As I wasn't able to push changes to this PR, I went ahead and merged your commit as 132fb66 via 7, leaving attribution intact.

@peteanning
Copy link
Contributor Author

peteanning commented Nov 6, 2022 via email

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

Labels

None yet

2 participants