I think you can keep the version number in the pom (there's a <version> element at the top).
It is pretty easy to access the POM version from Ant; from there you can create a file containing the version number, and have Clojure read that file at startup. However, this starts getting into the world of requiring the Maven Ant Tasks JAR to be present in order for the build to work. Just check it into Subversion, I say. An additional request: have the REPL display the version number at startup. On Wed, Apr 22, 2009 at 3:49 AM, Rich Hickey <richhic...@gmail.com> wrote: > > > > On Apr 21, 12:18 pm, Daniel Jomphe <danieljom...@gmail.com> wrote: >> Paul Stadig wrote: >> > Others have commented on the whole groupId, artifactId, etc., etc. But in >> > terms of the parts of the version number, they are named >> > <major>.<minor>.<incremental>-<qualifier> as documented here: >> >> >http://www.sonatype.com/books/maven-book/reference/pom-relationships-... >> >> Thanks for the info. >> >> So I was wrong in two ways: >> >> 1. There's in fact a convention for version strings: M.m.i-qualifier >> 2. The string "SNAPSHOT" may appear anywhere inside the version >> string. >> >> Keeping SNAPSHOT at the end and adding a "rc1" qualifier, to >> illustrate: >> >> version: 1.0.0-rc1-SNAPSHOT >> yields: clojure-1.0.0-rc1-<snapshot>.jar >> (and ...-slim.jar, ...-sources.jar) > > I've added *clojure-version* in SVN 1354. According to the above it's > still not quite right. I'm thinking now the runtime view should be > something like: > > {:major 1, :minor 0, :incremental 0, :qualifier :rc1 :interim true} > > for interim versions and > > {:major 1, :minor 0, :incremental 0} > > for releases. :interim tracks the SNAPSHOT segment of the version > string. > > A possible doc string: > > (doc *clojure-version*) > > The version info for Clojure core, as a map > containing :major :minor :incremental, and (optional) :qualifier > and :interim keys. Feature releases may increment :minor and/ > or :major, bugfix releases will increment :incremental. Possible > values of :qualifier include :rc, :beta etc, > and :interim will be true for non-release builds. > > I'm still left with a few questions and would appreciate some help. > > I don't mind the build producing clojure-1.0.0.jar etc, but it doesn't > now. The master build is Ant. Where is the best place to put the > version info so it can be leveraged by Ant, Maven and the clojure core > runtime in order to produce *clojure-version* ? > > What changes are needed to the build scripts to produce version- > numbered jars? > > Thanks, > > Rich > > > > -- Howard M. Lewis Ship Creator of Apache Tapestry Director of Open Source Technology at Formos --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en -~----------~----~----~----~------~----~------~--~---