Uh oh!
There was an error while loading. Please reload this page.
Add a version command - #400
Conversation
| desc "version", "Show the version of wraith" | ||
| def version | ||
| puts "Wraith version " + Wraith::VERSION |
There was a problem hiding this comment.
I would change this to logger.info Wraith::VERSION just to keep this consistent with the rest of the codebase (and not sure the "Wraith version" bit is necessary, other programs just output their version numbers).
ChrisBAshton
commented
Mar 11, 2016
Thanks for the PR, I wonder if this could work with i.e. I agree Wraith should have a version command, just not sure |
katekligman
commented
Mar 17, 2016
Thanks for the feedback! I've changed to logger.info and removed the 'Wraith version' from the output. For the version command itself: I've noticed other programs tend to stay somewhat consistent with the formats of their parameters. For example phantomjs uses '--' with other parameters so it would make sense for their version command to also have that prefix. That said, there are a lot of variations among other programs. I kept 'version' as the primary and documented Wraith command to stay consistent with the format of Wraith's other commands. I also mapped "-v", "--version" and "-version" to also invoke it. |
ChrisBAshton
commented
Mar 17, 2016
Fantastic! It would also be really helpful if you could make a PR to the gh-pages branch so that the new command is described in http://bbc-news.github.io/wraith/#Commandlineoptions. If not, I'll get around to it eventually! Thanks once again. |
Adds a version command to Wraith. Fix for #397.
When the command ‘wraith version’ is run it will output ‘Wraith version X.X.X’