drdoctr / doctr

A tool for automatically deploying docs from Travis CI to GitHub pages.
https://drdoctr.github.io
MIT License
107 stars 30 forks source link

Allow for multiple --command flags #354

Open goerz opened 5 years ago

goerz commented 5 years ago

It seems like if I give the --command flag multiple times, only the last command will be executed. I would expect each --command to be run, in the order it was specified.

I can work around this with --command="cmd1 && cmd2 && cmd3", but it would be nicer to have this as --command=cmd1 --command=cmd2 --command=cmd3 (or else, show an error if --command is given multiple times).

asmeurer commented 5 years ago

I think the current behavior is just the default argparse behavior where passing a flag multiple times just overrides the previous times. Allowing it to be passed multiple times sounds good to me.