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

Re: From a cvs user... about revisions

From: Harry Putnam <reader_at_newsguy.com>
Date: Sun, 11 Oct 2009 10:56:20 -0500

Pat Farrell <pfarrell_at_pfarrell.com> writes:

> Harry Putnam wrote:
>> I want to retrieve a certain copy of a file... where a change
>> happened. According to what I'm reading, that change may not be at
>> the last version number....or possibly even the last several version
>> numbers... so how do I find the change quickly?
>
> Unlike CVS which assigns a revision number to a file, SVN assigns a
> revision number to the whole repository.

Yeah I got that part... that is the source of my misgivings.

> But the log for each file has the revision history for that file, its
> just that the number will not go up by one for each change to the file.
>
> Use the 'svn log <file>" command to show the history of the <file>
> and you will see the specific revision numbers, just use that in the SVN
> command

> Here is a live snippet of one log of one of my files
>
> ------------------------------------------------------------------------
> r4195 | pfarrell | 2009-10-07 00:30:03 -0400 (Wed, 07 Oct 2009) | 1 line
>
> create Pat private branch
> ------------------------------------------------------------------------
> r4024 | pfarrell | 2009-10-01 02:02:04 -0400 (Thu, 01 Oct 2009) | 2 lines
>
> use safeForwardToView()
>
> ------------------------------------------------------------------------
> r3990 | pfarrell | 2009-09-29 14:29:16 -0400 (Tue, 29 Sep 2009) | 3 lines
>
> add subdirectory 'closed/' to urls that we expect to access when logged in.
>

> so if you want revision -r 3990, that's the one to use

Thanks ... good info. It appears that you may have actually made log
entries during commit... if you hadn't would it still be easy to find a
change?

I ask because during my cvs usage... I often commit without typing a
log comment. It can work because I'm the only user... and will often
be committing something I think is insignificant. But sometimes I'll
want to look up one of those `insignificant' changes, and will know it
was within a few commits ago or etc, so can call the revision straightaway.

I might say cvs status path/file,,, to see current rev number.. then

  cvs diff -r N.N path/file to examine differences or

  cvs co -p -r N.N path/file > ~/file

To get the actual revised file on STDOUT and redirect for a thorough
examination.

I guess maybe all the same things or similar things would be available
in subversion... but the book makes it sound as if you wouldn't be
able to associate specific changes with specific number of revisions
back... since other revisions not effecting the file of interest might
have occurred.

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=2406390

To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_subversion.tigris.org].
Received on 2009-10-11 17:58:00 CEST

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

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