You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by Marco Mans <Ma...@telemans.de> on 2005/07/06 07:48:13 UTC
Log entry of a deleted file
Hi!
Today I deleted a file in my working copy and did a commit (=rev 41).
After a while
I realized that I needed this file. So I did 'svn copy -r 40
http://blablalba/myfile ./myfile',
and commited again (now rev. 42). When I now look at the log-history of
this file I see
something like this:
------------------------------------------------------------------------
r42 | aschoenmakers | 2005-07-06 09:23:23 +0200 (Wed, 06 Jul 2005) | 2 lines
myFile re-added cause I needed it
------------------------------------------------------------------------
r39 | aschoenmakers | 2005-07-04 08:47:11 +0200 (Mon, 04 Jul 2005) | 7 lines
myFile initialy added
-----------------------------------------------------------------------
Why can't I see an entry for revision 41 where I deleted the file???
Thanx in advanced!
Greetings,
Marco Mans
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Log entry of a deleted file
Posted by Marco Mans <MM...@gti-ia-zo.nl>.
James Davis wrote:
>Marco Mans wrote:
>
>
>
>>Today I deleted a file in my working copy and did a commit (=rev 41).
>>
>>
>
>
>
>>Why can't I see an entry for revision 41 where I deleted the file???
>>
>>
>
>Did you actually just delete the file using rm from the working copy
>instead of deleting it through subversion using svn delete? That wasn't
>clear. Anyhow, if so, that's the expected behavior.
>
>James
>
>
>
James,
I used 'svn delete myFile'
Marco.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Log entry of a deleted file
Posted by James Davis <ja...@jml.net>.
Marco Mans wrote:
> Today I deleted a file in my working copy and did a commit (=rev 41).
> Why can't I see an entry for revision 41 where I deleted the file???
Did you actually just delete the file using rm from the working copy
instead of deleting it through subversion using svn delete? That wasn't
clear. Anyhow, if so, that's the expected behavior.
James
--
http://jamesd.ukgeeks.co.uk/
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Log entry of a deleted file
Posted by Ben Collins-Sussman <su...@collab.net>.
On Jul 7, 2005, at 8:38 AM, Joshua Varner wrote:
> Okay, this make sense. I just have one question and this isn't meant
> as a criticism I'm just trying to understand the behavior. If Adds and
> Deletes are considered changes to the containing directory, then what
> is the rationale for not updating the version of the directory when an
> Add or Delete occurs?
Suppose you have revision 10 of a working copy, and then create a new
file, 'svn add' it, then 'svn commit', creating revision 17 in the
repository. It's definitely correct to mark the newly-added file as
being at revision 17. But the parent dir? Not possible. Any number
of adds/deletes/propchanges could have happened to it between r10 and
r17. Claiming that we have r17 of the parent would be a lie. What
we have is r10 of the directory, with a few extra "things" added/
deleted lying around.
So what's really going on is that when a working copy claims to have
rX of a directory, it means,
* I have the exact set of properties that (rX, dir) is supposed
to have
* I have the exact set of children that (rX, dir) is supposed to
have, except for these exceptions:
(list of deleted objects)
(list of added objects)
When it finally comes time to 'svn update', the working copy
describes itself very carefully to the repository. It claims to have
rX of the directory, and lists any extra deleted/added objects
hanging around. The repository then settles up, possibly adds and
deletes more things, then tells the client it's okay to mark the
directory as being at rHEAD.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Log entry of a deleted file
Posted by Norbert Unterberg <nu...@gmail.com>.
2005/7/7, Joshua Varner <jl...@gmail.com>:
> Okay, this make sense. I just have one question and this isn't meant
> as a criticism I'm just trying to understand the behavior. If Adds and
> Deletes are considered changes to the containing directory, then what
> is the rationale for not updating the version of the directory when an
> Add or Delete occurs?
Becaus the directory has not really been updated to that revision. To
do so you need to run an svn update. Updating the directory can have
other effects becasue some other user could have changed directory
properties in the mean time. If you just update the revision number
locally, then the directory would not match the repository revision of
that directory. This can only be done by explicitly running the
update.
Norbert
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Log entry of a deleted file
Posted by Joshua Varner <jl...@gmail.com>.
On 7/6/05, Ben Collins-Sussman <su...@collab.net> wrote:
>
> On Jul 6, 2005, at 8:20 AM, Joshua Varner wrote:
> > I think this may be a bug. This is what I expected too, but I ran a
> > little test (given I'm only running 1.1.1), but if it is a change to
> > the parent why doesn't show up in it's log.
>
> Because your working copy of the parent directory is still at an
> older revision, run 'svn status -v' and see for yourself. When you
> run 'svn log .' you're asking, "give me the history of this very old
> directory object".
>
> This is one of the FAQs: http://subversion.tigris.org/
> faq.html#hidden-log
>
Okay, this make sense. I just have one question and this isn't meant
as a criticism I'm just trying to understand the behavior. If Adds and
Deletes are considered changes to the containing directory, then what
is the rationale for not updating the version of the directory when an
Add or Delete occurs?
It makes since not to update all of the other files in the directory,
but you know at the commit that the Add/Delete just committed is the
only change (Or at least that's my understanding), because the commit
would not go through without having updated the directory.
Just trying to get a handle on the current FAQs,
Josh
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Log entry of a deleted file
Posted by Ben Collins-Sussman <su...@collab.net>.
On Jul 6, 2005, at 8:20 AM, Joshua Varner wrote:
> I think this may be a bug. This is what I expected too, but I ran a
> little test (given I'm only running 1.1.1), but if it is a change to
> the parent why doesn't show up in it's log.
Because your working copy of the parent directory is still at an
older revision, run 'svn status -v' and see for yourself. When you
run 'svn log .' you're asking, "give me the history of this very old
directory object".
This is one of the FAQs: http://subversion.tigris.org/
faq.html#hidden-log
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Log entry of a deleted file
Posted by Joshua Varner <jl...@gmail.com>.
On 7/6/05, Ben Collins-Sussman <su...@collab.net> wrote:
>
> On Jul 6, 2005, at 2:48 AM, Marco Mans wrote:
>
> > Hi!
> >
> > Today I deleted a file in my working copy and did a commit (=rev
> > 41). After a while
> > I realized that I needed this file. So I did 'svn copy -r 40 http://
> > blablalba/myfile ./myfile',
> > and commited again (now rev. 42). When I now look at the log-
> > history of this file I see
> > something like this:
> >
> > ----------------------------------------------------------------------
> > --
> > r42 | aschoenmakers | 2005-07-06 09:23:23 +0200 (Wed, 06 Jul 2005)
> > | 2 lines
> > myFile re-added cause I needed it
> > ----------------------------------------------------------------------
> > --
> > r39 | aschoenmakers | 2005-07-04 08:47:11 +0200 (Mon, 04 Jul 2005)
> > | 7 lines
> > myFile initialy added
> > ----------------------------------------------------------------------
> > -
> >
> > Why can't I see an entry for revision 41 where I deleted the file???
>
> Because r41 isn't a change to the file, it's a change to its parent.
>
> If you ask for the history of just the file itself, you'll see all
> edits, back to the point where the file was copied. Then the copy
> action will be 'traversed' back to r39, which is the history of the
> original file the copy was made from.
>
>
I think this may be a bug. This is what I expected too, but I ran a
little test (given I'm only running 1.1.1), but if it is a change to
the parent why doesn't show up in it's log.
Below is a sample session where I replicated the situation from the
original e-mail and found that the only way to access the log message
on revision six is with a -r. No object in the repository had the log
attached to it.
Josh
[josh@lcc51 scratch]$ cd dir1/
[josh@lcc51 dir1]$ ls
file1 file2 file3 ignore1
[josh@lcc51 dir1]$ svn remove file1
D file1
[josh@lcc51 dir1]$ svn commit -m "Removed file1"
Deleting dir1/file1
Committed revision 6.
[josh@lcc51 dir1]$ svn cp -r 5 svn://svn/scratch/trunk/dir1/file1 .
A file1
[josh@lcc51 dir1]$ svn commit -m "readded file1
> "
Adding dir1/file1
Committed revision 7.
[josh@lcc51 dir1]$ svn log file1
------------------------------------------------------------------------
r7 | scratch | 2005-07-06 08:02:01 -0500 (Wed, 06 Jul 2005) | 2 lines
readded file1
------------------------------------------------------------------------
r5 | scratch | 2005-06-08 14:29:36 -0500 (Wed, 08 Jun 2005) | 1 line
Removed local changes and reset svn:ignore
------------------------------------------------------------------------
r3 | scratch | 2005-06-08 14:01:33 -0500 (Wed, 08 Jun 2005) | 3 lines
Added ignore property
------------------------------------------------------------------------
r2 | scratch | 2005-06-08 13:58:04 -0500 (Wed, 08 Jun 2005) | 2 lines
Test files
------------------------------------------------------------------------
[josh@lcc51 dir1]$ svn log .
------------------------------------------------------------------------
r5 | scratch | 2005-06-08 14:29:36 -0500 (Wed, 08 Jun 2005) | 1 line
Removed local changes and reset svn:ignore
------------------------------------------------------------------------
r4 | scratch | 2005-06-08 14:23:30 -0500 (Wed, 08 Jun 2005) | 1 line
Removed svn:ignore
------------------------------------------------------------------------
r3 | scratch | 2005-06-08 14:01:33 -0500 (Wed, 08 Jun 2005) | 3 lines
Added ignore property
------------------------------------------------------------------------
r2 | scratch | 2005-06-08 13:58:04 -0500 (Wed, 08 Jun 2005) | 2 lines
Test files
------------------------------------------------------------------------
[josh@lcc51 dir1]$ svn log -r 6
------------------------------------------------------------------------
r6 | scratch | 2005-07-06 07:59:38 -0500 (Wed, 06 Jul 2005) | 1 line
Removed file1
------------------------------------------------------------------------
[josh@lcc51 dir1]$ svn log -r 6 file1
svn: File not found: revision 6, path '/trunk/dir1/file1'
[josh@lcc51 dir1]$ svn --version
svn, version 1.1.1 (r11581)
compiled Dec 15 2004, 14:58:14
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Log entry of a deleted file
Posted by Ben Collins-Sussman <su...@collab.net>.
On Jul 6, 2005, at 2:48 AM, Marco Mans wrote:
> Hi!
>
> Today I deleted a file in my working copy and did a commit (=rev
> 41). After a while
> I realized that I needed this file. So I did 'svn copy -r 40 http://
> blablalba/myfile ./myfile',
> and commited again (now rev. 42). When I now look at the log-
> history of this file I see
> something like this:
>
> ----------------------------------------------------------------------
> --
> r42 | aschoenmakers | 2005-07-06 09:23:23 +0200 (Wed, 06 Jul 2005)
> | 2 lines
> myFile re-added cause I needed it
> ----------------------------------------------------------------------
> --
> r39 | aschoenmakers | 2005-07-04 08:47:11 +0200 (Mon, 04 Jul 2005)
> | 7 lines
> myFile initialy added
> ----------------------------------------------------------------------
> -
>
> Why can't I see an entry for revision 41 where I deleted the file???
Because r41 isn't a change to the file, it's a change to its parent.
If you ask for the history of just the file itself, you'll see all
edits, back to the point where the file was copied. Then the copy
action will be 'traversed' back to r39, which is the history of the
original file the copy was made from.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org