[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Incorrect usage shouldn't give a long help message [was: [PATCH] Move multiple targets]

From: Julian Foad <julianfoad_at_btopenworld.com>
Date: 2005-11-08 14:36:37 CET

Hyrum K. Wright wrote:
>
> Something else I noticed is that when svn mv is run without arguments,
> it prints the command line help, but when something like svn propset is
> run, it just errors with 'Too few arguments'. I suspect there are other
> commands like this. Should their behavior be changed to be consistent
> with move, or should move just error out? Personally, I think that the
> former idea a better help for the user.

(I'm replying to this part of your mail first, because it's easy to do so.)

Printing help may be more helpful to a novice in the short term, but in the
long term it gives a false sense of security, causing users to develop a bad
habit. It's bad because not all commands print help when invoked without
arguments. Also, when invoking the command accidentally without arguments
(perhaps giving as an argument an environment variable which was accidentally
undefined), printing a long help message is annoying. Also it makes a
compatibility problem if we want to extend a command to have an argument-free
form in the future.

Incorrect usage should result in an error message, consistently for all
commands. It's been on my "to do" list for years. Perhaps now I'll do it.

- Julian

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Tue Nov 8 14:37:29 2005

This is an archived mail posted to the Subversion Dev mailing list.