[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

RSCM and subversion

Craig Beck

2/15/2007 3:43:00 AM

Anyone know how to get the svn revision number of a locally checked-
out working copy via rscm?

I've hacked about a bit in irb to see how things work (the docs are a
little thin) but this one thing has eluded me. It can tell me if the
WC is not the current version -- but only the current version AFAIK
which is different from (a) the actual checked-out revision and (b)
is the current local revision up-to-date (which does not mean == to
the HEAD revision)

Am I just blind, or does rscm lack the ability to tell me what the
revision number is a la `svn info`? (and yes, I can fall back to
parsing the output of `svn info`

--
Craig Beck

AIM: kreiggers



1 Answer

Alexey Verkhovsky

2/15/2007 6:19:00 AM

0

Craig Beck wrote:
> Anyone know how to get the svn revision number of a locally
> checked-out working copy via rscm?
>
> I've hacked about a bit in irb to see how things work (the docs are a
> little thin) but this one thing has eluded me. It can tell me if the
> WC is not the current version -- but only the current version AFAIK
> which is different from (a) the actual checked-out revision and (b) is
> the current local revision up-to-date (which does not mean == to the
> HEAD revision)
>
> Am I just blind, or does rscm lack the ability to tell me what the
> revision number is a la `svn info`? (and yes, I can fall back to
> parsing the output of `svn info`
We have just solved this problem, and you can probably adopt some code
from here:
http://rubyforge.org/viewvc/trunk/app/models/subversion.rb?revision=103&root=cruisecontrolrb&v...
Specifically, look for Subversion#latest_revision method.

Best regards,
Alex Verkhovsky