Projects

Ticket #173 (closed defect: fixed)

Opened 22 months ago

Last modified 21 months ago

Need to expose the SVN revision number as a constant

Reported by: lsansonetti@… Owned by: lsansonetti@…
Priority: blocker Milestone: MacRuby 0.4
Component: MacRuby Keywords:
Cc:

Description

It would be great for debugging purposes to expose the SVN revision number as a constant in MacRuby. Maybe MACRUBY_REVISION.

Change History

Changed 22 months ago by self@…

One thing to keep in mind is that if you ever move to a VCS like Git (although this issue is not exclusive to Git) you lose the concept of a "revision number". For example Git commits are identified by a hash.

Changed 21 months ago by lsansonetti@…

  • status changed from new to closed
  • resolution set to fixed
  • milestone changed from MacRuby 1.0 to MacRuby 0.4

A patch was contributed by Vincent Isambart that implements this feature. It works for both SVN and Git.

$ ./miniruby -e "p MACRUBY_REVISION"
"svn revision 745 from http://svn.macosforge.org/repository/ruby/MacRuby/trunk"

It has been committed as r766.

Changed 21 months ago by lsansonetti@…

  • status changed from closed to reopened
  • resolution fixed deleted

Looking more carefully, looks like the revision number is not the latest one. I pinged Vincent. Re-opening the ticket.

Changed 21 months ago by lsansonetti@…

  • status changed from reopened to closed
  • resolution set to fixed

Forgot to do "svn update", mea culpa :-)

Note: See TracTickets for help on using tickets.