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

AW: How to find out the rev number where a file was deleted?

From: Paul Maier <svn-user_at_web.de>
Date: Sat, 27 Nov 2010 13:42:56 +0100

Hi Edward,

thanks for having responded.
Can I file a feature request for that in the issue tracker,
what do you think?

@Ryan: Of course with a peg rev I can log that single rev. But the
rev number of that rev is that what we are looking for! To find out
this rev number, we want to use an earlier peg rev where we know
that the file still existed and want to add "-r1:head" as operative
revs to see all revs including the rev where the file was deleted.

Paul.
 

> -----Ursprüngliche Nachricht-----
> Von: Edward Ned Harvey [mailto:svn_at_nedharvey.com]
> Gesendet: Samstag, 27. November 2010 05:33
> An: svn-user_at_web.de; users_at_subversion.apache.org
> Betreff: RE: How to find out the rev number where a file was deleted?
>
> > From: svn-user_at_web.de [mailto:svn-user_at_web.de]
> >
> > I would appreciate advice for how to find out the rev
> number where a file
> > was deleted or moved.
> >
> > I expected this command:
> > svn log -v -r 1:head "file:///[...]/xx/a_at_1"
>
> Yeah. This is annoying. Once a file is deleted, I can't svn log it
> anymore. Even if I specify a rev where the file existed.
>
> <ok to skip this section>
> [user_at_machine ~]# mkdir trash
> [user_at_machine ~]# cd trash/
> [user_at_machine trash]# mkdir repo
> [user_at_machine trash]# svnadmin create repo
> [user_at_machine trash]# mkdir working
> [user_at_machine trash]# svn co file:///home/user/trash/repo working
> Checked out revision 0.
> [user_at_machine trash]# cd working/
> [user_at_machine working]#
> [user_at_machine working]#
> [user_at_machine working]#
> [user_at_machine working]# touch foo
> [user_at_machine working]# svn add foo
> A foo
> [user_at_machine working]# svn commit -m 'first commit' foo
> Adding foo
> Transmitting file data .
> Committed revision 1.
> [user_at_machine working]# echo "a" > foo
> [user_at_machine working]# svn commit -m 'second commit' foo
> Sending foo
> Transmitting file data .
> Committed revision 2.
> [user_at_machine working]# svn log foo
> --------------------------------------------------------------
> ----------
> r2 | user | 2010-11-26 23:25:59 -0500 (Fri, 26 Nov 2010) | 1 line
>
> second commit
> --------------------------------------------------------------
> ----------
> r1 | user | 2010-11-26 23:25:46 -0500 (Fri, 26 Nov 2010) | 1 line
>
> first commit
> --------------------------------------------------------------
> ----------
> </ok>
>
>
> Here's the important part:
>
>
> [user_at_machine working]# svn rm foo
> D foo
> [user_at_machine working]# svn commit -m 'deleted' foo
> Deleting foo
>
> Committed revision 3.
> [user_at_machine working]# svn log foo
> svn: 'foo' is not under version control
> [user_at_machine working]# ls
> .svn/
> [user_at_machine working]# svn log -r 2 foo
> svn: 'foo' is not under version control
> [user_at_machine working]# svn log -r 1 foo
> svn: 'foo' is not under version control
> [user_at_machine working]# svn --version
> svn, version 1.6.2 (r37639)
> compiled May 11 2009, 11:51:14
>
>
>
>
Received on 2010-11-27 13:43:50 CET

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.