Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

same for `cmd -v` `cmd --version`


The first one is verbose, not version, though? Not sure if you're used to a set of utilities that doesn't intersect the ones I'm used to where -v is version. I've seen -V, though.

And then there's grep


I agree that -V is more common. I have used a few things that use -v for version though (I think `ruby` does, which led to some confusion for me the first time I tried to pass that to `python` and instead of getting the version number found myself in a more chatty than normal python shell).


The cat command is rather infamous for using -v to mean “visual” (as in, convert invisible characters to something visible).

But the infamy is not that it used -v for something other than “version”—I doubt that convention existed in 1983, when the complaint was made—but rather that it was a sign of the ever‐growing complexity of specific Unix tools at the expense of the harmony of the whole system.

See “Program design in the UNIX environment,” by Rob Pike and Brian Kernighan, USENIX 1983: http://harmful.cat-v.org/cat-v/


Defacto short switch for version is "-V". "-v" is verbose.


As is quite clear in this thread, there really is no unified way of doing things.

Uppercase switches also strikes me as not very intuitive, either you need to look at the help page or you have to have the same mindset as the developer.

And still, the distinction between lowercase and uppercase switches are not easy to remember.

For the power user though it makes sense.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: