You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by Kevin Hung <cy...@yahoo.com> on 2005/06/24 16:12:24 UTC

Wrong revision number from running "svn list -v" on local working directory.

I am learning Subversion and playing around with it. I
run into problem with running "svn list" on local
working directory. I have two files in my local
working directory. My understanding (after reading the
svn book) is that running "svn list -v" on local
directory is that same as running "svn list -v" on
repository directory. However, it does not seem to be
true.

/home/khung/wcdma> svn list -v
      7 khung          1232 Jun 23 14:22 help.txt
      7 khung         27648 Jun 23 14:22 wcdma.xls

/home/khung/wcdma> svn list
file:///home/khung/repos/wcdma/trunk -v
     10 khung          1395 Jun 23 18:18 help.txt
     11 khung         27648 Jun 23 18:27 wcdma.xls

The latest revision number of help.txt is 10 and the
latest revision number of wcdma.xls is 11. So the
revision number returned by "svn list -v" on local
working directory is wrong.

I get correct revision number if I run the same
command on local file (instead of local directory).

/home/khung/wcdma> svn list help.txt -v
     10 khung          1395 Jun 23 18:18 help.txt
/home/khung/wcdma> svn list wcdma.xls -v
     11 khung         27648 Jun 23 18:27 wcdma.xls

Am I missing something?

Thanks.




__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org

Re: Wrong revision number from running "svn list -v" on local working directory.

Posted by Kevin Hung <cy...@yahoo.com>.

--- Dominic Anello <da...@danky.com> wrote:

> On 2005-06-25 10:07:57 -0700, Kevin Hung wrote:
> > --- Dominic Anello <da...@danky.com> wrote:
> > > On 2005-06-24 09:12:24 -0700, Kevin Hung wrote: 
> ----8<----
> > Hi Donminic,
> > 
> > Thank you very much for your tip. You are correct.
> > Once I use the command "svn list -r HEAD -v .",
> then
> > svn returns the correct revision number.
> > 
> > However, do you think there is some inconsistency
> in
> > this command? For example, if I do "svn list
> help.txt
> > -v", then it works. Should the command "svn ls -v"
> be
> > translated into "svn list -r HEAD -v ."?
> 
> It's not inconsistent because the first command you
> give is specifically
> targeting a file, while the second is implicitly
> targeting a current
> directory.
> 
> So if the directory is at r7 and the file is at r9,
> then the first
> command will list the file at r9, while the second
> command will list the
> contents of the directory *as it exists in the
> repository* at r7.
> 
>  
> > So should I always "svn list -r HEAD -v" (via
> alias)
> > on everything (eg. local file, local directory,
> > repository file and repository directory)?
> 
> Either that or get in the habit of doing an "svn up"
> after committing.
> 
> -Dominic
> 

Great. Thanks for the tip.

Kevin.


		
__________________________________ 
Yahoo! Mail Mobile 
Take Yahoo! Mail with you! Check email on your mobile phone. 
http://mobile.yahoo.com/learn/mail 

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org

Re: Wrong revision number from running "svn list -v" on local working directory.

Posted by Dominic Anello <da...@danky.com>.
On 2005-06-25 10:07:57 -0700, Kevin Hung wrote:
> --- Dominic Anello <da...@danky.com> wrote:
> > On 2005-06-24 09:12:24 -0700, Kevin Hung wrote: 
----8<----
> Hi Donminic,
> 
> Thank you very much for your tip. You are correct.
> Once I use the command "svn list -r HEAD -v .", then
> svn returns the correct revision number.
> 
> However, do you think there is some inconsistency in
> this command? For example, if I do "svn list help.txt
> -v", then it works. Should the command "svn ls -v" be
> translated into "svn list -r HEAD -v ."?

It's not inconsistent because the first command you give is specifically
targeting a file, while the second is implicitly targeting a current
directory.

So if the directory is at r7 and the file is at r9, then the first
command will list the file at r9, while the second command will list the
contents of the directory *as it exists in the repository* at r7.

 
> So should I always "svn list -r HEAD -v" (via alias)
> on everything (eg. local file, local directory,
> repository file and repository directory)?

Either that or get in the habit of doing an "svn up" after committing.

-Dominic

Re: Wrong revision number from running "svn list -v" on local working directory.

Posted by Kevin Hung <cy...@yahoo.com>.

--- Dominic Anello <da...@danky.com> wrote:

> On 2005-06-24 09:12:24 -0700, Kevin Hung wrote:
> > I am learning Subversion and playing around with
> it. I
> > run into problem with running "svn list" on local
> > working directory. I have two files in my local
> > working directory. My understanding (after reading
> the
> > svn book) is that running "svn list -v" on local
> > directory is that same as running "svn list -v" on
> > repository directory. However, it does not seem to
> be
> > true.
> > 
> > /home/khung/wcdma> svn list -v
> >       7 khung          1232 Jun 23 14:22 help.txt
> >       7 khung         27648 Jun 23 14:22 wcdma.xls
> > 
> > /home/khung/wcdma> svn list
> > file:///home/khung/repos/wcdma/trunk -v
> >      10 khung          1395 Jun 23 18:18 help.txt
> >      11 khung         27648 Jun 23 18:27 wcdma.xls
> > 
> > The latest revision number of help.txt is 10 and
> the
> > latest revision number of wcdma.xls is 11. So the
> > revision number returned by "svn list -v" on local
> > working directory is wrong.
> > 
> > I get correct revision number if I run the same
> > command on local file (instead of local
> directory).
> > 
> > /home/khung/wcdma> svn list help.txt -v
> >      10 khung          1395 Jun 23 18:18 help.txt
> > /home/khung/wcdma> svn list wcdma.xls -v
> >      11 khung         27648 Jun 23 18:27 wcdma.xls
> > 
> > Am I missing something?
> ----8<----
> 
> What you are missing is that you are probably
> dealing with a mixed
> revision working copy.
> 
> If you do:
> /home/khung/wcdma> svn info
> 
> You will probably see that the wcdma directory is
> somwhere between r7
> and r9.
> 
> Remember that 
> /home/khung/wcdma> svn ls -v
> 
> translates into 
> /home/khung/wcdma> svn list -r BASE -v .
> 
> So if wcdma is not at HEAD, you will see different
> results than when
> listing the URL without a revision argument.
> 
> -Dominic
> 

Hi Donminic,

Thank you very much for your tip. You are correct.
Once I use the command "svn list -r HEAD -v .", then
svn returns the correct revision number.

However, do you think there is some inconsistency in
this command? For example, if I do "svn list help.txt
-v", then it works. Should the command "svn ls -v" be
translated into "svn list -r HEAD -v ."?

So should I always "svn list -r HEAD -v" (via alias)
on everything (eg. local file, local directory,
repository file and repository directory)?

Thanks.
Kevin


__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org

Re: Wrong revision number from running "svn list -v" on local working directory.

Posted by Dominic Anello <da...@danky.com>.
On 2005-06-24 09:12:24 -0700, Kevin Hung wrote:
> I am learning Subversion and playing around with it. I
> run into problem with running "svn list" on local
> working directory. I have two files in my local
> working directory. My understanding (after reading the
> svn book) is that running "svn list -v" on local
> directory is that same as running "svn list -v" on
> repository directory. However, it does not seem to be
> true.
> 
> /home/khung/wcdma> svn list -v
>       7 khung          1232 Jun 23 14:22 help.txt
>       7 khung         27648 Jun 23 14:22 wcdma.xls
> 
> /home/khung/wcdma> svn list
> file:///home/khung/repos/wcdma/trunk -v
>      10 khung          1395 Jun 23 18:18 help.txt
>      11 khung         27648 Jun 23 18:27 wcdma.xls
> 
> The latest revision number of help.txt is 10 and the
> latest revision number of wcdma.xls is 11. So the
> revision number returned by "svn list -v" on local
> working directory is wrong.
> 
> I get correct revision number if I run the same
> command on local file (instead of local directory).
> 
> /home/khung/wcdma> svn list help.txt -v
>      10 khung          1395 Jun 23 18:18 help.txt
> /home/khung/wcdma> svn list wcdma.xls -v
>      11 khung         27648 Jun 23 18:27 wcdma.xls
> 
> Am I missing something?
----8<----

What you are missing is that you are probably dealing with a mixed
revision working copy.

If you do:
/home/khung/wcdma> svn info

You will probably see that the wcdma directory is somwhere between r7
and r9.

Remember that 
/home/khung/wcdma> svn ls -v

translates into 
/home/khung/wcdma> svn list -r BASE -v .

So if wcdma is not at HEAD, you will see different results than when
listing the URL without a revision argument.

-Dominic