Mark Phippard wrote:
> Del Myers <delmyers.cs@gmail.com> wrote on 09/22/2006 03:11:56 PM:
>
>> Mark Phippard wrote:
>>> Del Myers <delmyers.cs@gmail.com> wrote on 09/22/2006 01:37:17 PM:
>>>
>>>>> Adding or subtracting 1, depending on your need, will always work.
>>>>>
>>>>> As for the special values, they corresponds to the special revision
>>>>> keywords that Subversion supports. See this section of the book for
>
>>> an
>>>>> explanation of each:
>>>>>
>>>>>
> http://svnbook.red-bean.com/en/1.2/svn.tour.revs.html#svn.tour.revs.keywords
>>>>> Mark
>>>> Thanks Mark, but I'm still having problems. For example, if I call
>>>> ISVNRemoteResource.getRevision(), and it returns a value like
>>> SVNRevision.HEAD,
>>>> I can't find a way to convert that to an actual revision number. Any
>>>> suggestions? Thanks.
>>> There is definitely no way to convert the special values to numbers.
> That
>>> being said, I do not believe there are any instances when requesting
> the
>>> revision from a resource that you will ever get anything except a
> revision
>>> number.
>> Actually ISVNRemoteResource.getRevision() did give me a HEAD revision,
> not a
>> number. I discovered this while trying to cast it to a number. Any
> suggestions?
>
> For what do you want suggestions?
>
> How did you get the remote resource to begin with? You could run svn info
> on the repository root URL and get the revision number from that to know
> what HEAD is. You should be able to do it on the item itself, to gets its
> HEAD revision.
>
> Mark
I just need to get the revision number. The error came along while I was doing
the following:
First, I got an ISVNLocalResource svnProject from an IProject, then:
ISVNRemoteResource remote = svnProject.getRemoteResource();
ISVNRevision revision = remote.getRevision();
That's it. The revision that I got was SVNRevision.HEAD. What I really want is
the number.
Thanks.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subclipse.tigris.org
For additional commands, e-mail: users-help@subclipse.tigris.org
Received on Fri Sep 22 21:48:37 2006