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

Re: Check min and max num targets in client args patch.

From: Mo DeJong <mdejong_at_cygnus.com>
Date: 2001-03-14 03:50:15 CET

On Mon, 12 Mar 2001, B. W. Fitzpatrick wrote:

<snip>

> > Would it be better to simply pass the
> > apr_getopt_t to the command and let
> > it deal with separating the initial
> > arguments from the target arguments?
>
> My initial thought was "goodness no!" but upon further reading, I
> changed my mind (see below).

<snip>

> Urk... that's a *really* good point. It's obvious that we need to
> rethink this argument processing... I'm going to take a step back and
> try and formulate (in English) exactly what we need to handle/provide
> here, and then try and code from there. I'm thinking that a more
> holistic approach is required here (one approach that takes into
> account all the cases) instead of a bunch of different techniques.
>
> -Fitz

While this is bouncing around in your brain, let me toss
just one more idea in there. It sure would be nice if
it were possible to test argument parsing and subcommand
option parsing without having a valid checkout on disk.
Perhaps a special svn_echo executable could be compiled
with a special -D flag.

% svn_echo update -s one one/two.txt
SVN_ECHO:
options:
subcommand: update
subcommand options: -s
targets: one one.two.txt

That would make writing test cases a lot easier
since you could cover commands like "svn checkout"
without actually checking something out.

Mo DeJong
Red Hat Inc
Received on Sat Oct 21 14:36:25 2006

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

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.