Thanks for pointing out the differece between "svn status" and "svn diff". I
guess what I am looking for is the exact combination of both. So I will just
use both at the same time.
On 9/9/06, Duncan Murdoch <email@example.com> wrote:
> On 9/9/2006 3:07 AM, Kevin Hung wrote:
> > Sorry that I did not state it clearly in my last posting. When I say
> > files or new directories", I mean the new files and new directories that
> > create in my working copy. They have not been added nor committed to the
> > repository.
> If they haven't been added or committed, then the revision number is
> irrelevant: they aren't under version control. Use svn status to list
> them. It tells about the status of your working copy, and will list
> those files with ? entries (unless you've configured svn to ignore them,
> as you might do for object files, etc.).
> svn diff will tell you about files that are under version control. You
> need to add those files, then you can see a diff versus whichever
> version you want.
> Duncan Murdoch
> > I have actually created a test repository and tried things out. So far,
> > have tried these two commands:
> > "svn diff -r 1000 ."
> > "svn diff -r 990:1000 ."
> > I think the first command compares my working copy to revision 1000 in
> > repository. However, this does not show any new file or new directory
> that I
> > create in my working copy.
> > The second command compares revision 990 and revision 1000 in the
> > repository. It does not look at my working copy.
> > I have also tried this,
> > svn diff /home/wc https://repos/proj@1000
> > But I get an error message from svn.
> > On 9/8/06, Blair Zajac <firstname.lastname@example.org> wrote:
> >> Kevin Hung wrote:
> >>> Hi Blair,
> >>> Just want to confirm the answer to my first question. Is it true that
> >>> there is no way to have "svn diff" to show new files or new
> >>> Would this feature be included in future release?
> >> No, that's not true. If you do a diff on a revision range that
> >> an
> >> added file, then the diff, either against the wc or the server, will
> >> the diff.
> >> BTW, you can always test things out very quickly using a test
> >> svnadmin create repos
> >> svn co file://`pwd`/repos wc
> >> cd wc
> >> cp /etc/motd .
> >> svn add motd
> >> svn ci -m ''
> >> cd ..
> >> svn diff -r 0:1 file://`pwd`/repos
> >> Regards,
> >> Blair
Received on Sat Sep 9 20:01:30 2006