gobanos / cargo-aoc

447 stars 47 forks source link

Specify a different input file #25

Closed samueltardieu closed 5 years ago

samueltardieu commented 5 years ago

It would be great if cargo aoc would let us specify an alternate input file. This way, it could be easier to run our code over examples or other people's inputs, for example when assisting them.

parbo commented 5 years ago

How do I use this?

samueltardieu commented 5 years ago

cargo aoc -i /tmp/input.txt, or cargo aoc -d 22 -i /tmp/input.txt for example.

parbo commented 5 years ago
$ cargo aoc -d 3 -p 2 -i input/2018/day3_test.txt
error: Found argument '-i' which wasn't expected, or isn't valid in this context

USAGE:
    cargo-aoc.exe <dummy> -d <day> -p <part>

For more information try --help

This doesn't seem to be available in what's on crates.io.