bug-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

cvs log options ( was Re: cvs rtag -r BRANCH -D date)


From: Stephen Rasku
Subject: cvs log options ( was Re: cvs rtag -r BRANCH -D date)
Date: Mon, 11 Jun 2001 09:00:15 -0700 (PDT)

Derek Price wrote:

>Ken.Olstad@lawson.com wrote:
>
>> larry.jones@sdrc.com writes:
>> > Simply allowing both -r and -D is intuitive, but it does cause
>> > problems for diff.  I'm throughly undecided about what the best
>> > approach is.
>>
>> One option to specify one revision (-r<branch>:<date>) seems cleaner
>> than two (-r<branch> -D<date>) in all cases, especially where more
>> than one option may be specified, as in cvs log and cvs diff.  The
>> choice of ':' was unfortunate, though, because it conflicts with the
>> RCS-style revision range specification, as in 'cvs log
>> -r<rev1>:<rev2>'.  The '@' character, as in <branch>@<date>, would
>> have been a nice choice.  Come to think of it, since '@' isn't legal
>> in revision numbers, tags, or dates (I think), maybe support for this
>> syntax could be added (everywhere: for diff -r, update -r, update -j,
>> get -r, ...) without breaking anything.
>>
>> Anybody see problems with this?
>
>Maybe.  I'm not sure about the datespec rules either, but if we go with
>'@', I'm going to say date@branch is probably the more generally
>intuitive way to select a point (date) on a branch due to the meaning
>already assigned to '@' in other (non-cvs) contexts.
>

Can we try and standardize across the various commands.  There are several 
ways to specify various options.  It appears to be mostly consistent 
except for "cvs log".

"cvs update, checkout, rtag, tag" all take revisions with -r.  You can 
include or omit the space between the -r and the revision.  However for 
"cvs log" you have to omit the space.  "cvs log" should be modified so 
that you don't have to omit the space.

cvs admin -o uses a colon syntax to specify a revision range and cvs log 
uses the same (or similar) syntax to specify revisions (except for the 
space problem mentioned above) but it uses a different syntax for dates.  
First of all, it uses -d instead of -D and it uses a greater than/less 
than syntax.  I would prefer using a -D syntax that mirrors the -r syntax. 
 So you would do some thing like this:

        cvs log -D <date> -D now
        cvs log -D start -D <date>
        cvs log -D <date1> -D <date2>
        etc.
        
I would also change the -r option so that it matches "cvs update" and "cvs 
diff".  It would work like this:

        cvs log -r <rev1> -r <rev2>
        cvs log -r <rev>.origin -r <rev>
        cvs log -r <rev> -r HEAD
        cvs log -r <branch>
        cvs log -r <branch1> -r <branch2>
        
-- 
Stephen Rasku                   E-mail: stephen@tgivan.com
Senior Software Engineer        Web:    http://www.pop-star.net/
TGI Technologies




reply via email to

[Prev in Thread] Current Thread [Next in Thread]