Return-Path: Delivered-To: apmail-maven-continuum-users-archive@www.apache.org Received: (qmail 77335 invoked from network); 2 Aug 2006 16:50:50 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 2 Aug 2006 16:50:50 -0000 Received: (qmail 768 invoked by uid 500); 2 Aug 2006 16:50:49 -0000 Delivered-To: apmail-maven-continuum-users-archive@maven.apache.org Received: (qmail 741 invoked by uid 500); 2 Aug 2006 16:50:48 -0000 Mailing-List: contact continuum-users-help@maven.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: continuum-users@maven.apache.org Delivered-To: mailing list continuum-users@maven.apache.org Received: (qmail 729 invoked by uid 99); 2 Aug 2006 16:50:48 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 02 Aug 2006 09:50:48 -0700 X-ASF-Spam-Status: No, hits=0.5 required=10.0 tests=DNS_FROM_RFC_ABUSE,HTML_MESSAGE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: domain of binil.thomas.public@gmail.com designates 64.233.182.189 as permitted sender) Received: from [64.233.182.189] (HELO nf-out-0910.google.com) (64.233.182.189) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 02 Aug 2006 09:50:47 -0700 Received: by nf-out-0910.google.com with SMTP id q29so711873nfc for ; Wed, 02 Aug 2006 09:50:26 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:references; b=dWKcnSiHgZzxwKwgdGbQtJEmNLXHCAOYeH0wN96gAx5b2WZbeEvyT21uE9rfBeibljLxbJJ+6TkAHe+n9hTmFcP+EWgAX97vDvLwpuHjcj3+w1GEiK6HRK/3janiNN2Q3xG/uPxQSFOYfIvtGDX6bul8ByDhOIUfAPFulfjEoyI= Received: by 10.82.102.5 with SMTP id z5mr297827bub; Wed, 02 Aug 2006 09:50:26 -0700 (PDT) Received: by 10.82.120.8 with HTTP; Wed, 2 Aug 2006 09:50:26 -0700 (PDT) Message-ID: <6762a1400608020950m17287053lba828296c9a23efe@mail.gmail.com> Date: Wed, 2 Aug 2006 22:20:26 +0530 From: "Binil Thomas" To: continuum-users@maven.apache.org Subject: Re: SVN Revision Number in the name of a snapshot artifact In-Reply-To: <6762a1400608020908l4db448c5ifc9d3bafa1474665@mail.gmail.com> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_487_8222944.1154537426168" References: <6762a1400608010409r8931ab4x45139c2654c66a88@mail.gmail.com> <6762a1400608020557s33baba4dh9561dc3df05ad69c@mail.gmail.com> <6762a1400608020908l4db448c5ifc9d3bafa1474665@mail.gmail.com> X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N ------=_Part_487_8222944.1154537426168 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline The discussion at http://mail-archives.apache.org/mod_mbox/maven-users/200602.mbox/%3CC4A30E18-FB31-4DBB-8B51-CD3A6C8F94BA@ucalgary.ca%3Eis useful in this context. Thanks, Binil On 8/2/06, Binil Thomas wrote: > > Thanks for replying! > > I think I understand this better now. In my build logs, I have > > [INFO] [deploy:deploy] > [INFO] Retrieving previous build number from artifacts > Uploading: /path/to/shared/repo/project/mymodule/1.0-SNAPSHOT/mymodule- > 1.0-20060802.093051-13.jar > 71K uploaded > > So, it looks like Maven looks at the shared repository, and figures out a > version qualifier & build number. The qualifier is the timestamp and build > number is figured out by incrementing the last build number. In my case, I > guess, since I started from a clean repository and no build has failed yet, > the build number corresponds to Continuum build number (which mislead me > into thinking that Continuum decides the build number). > > I will try the Maven user list. > > Thanks, > Binil > > > On 8/2/06, Jesse McConnell wrote: > > > > ah I see where your going, have you tried the maven users list? that > > is very much something that would be configured directly in maven, if > > it can be done like you are shooting for, which I am not to confident > > would be supported without adding some custom artifact resolvers. > > > > cheers! > > > > On 8/2/06, Binil Thomas wrote: > > > Hi Jesse, > > > > > > Thanks for the reply. > > > > > > I am using SNAPSHOT dependencies between modules. Continuum does > > generate > > > the SNAPSHOT binaries with a timestamp, and Maven 2 lets developers > > depend > > > on the latest SNAPSHOT automatically. All that functionality you > > mention > > > works fine for me. > > > > > > Since the SCM I am using - SVN - does version the repository by > > revision > > > numbers, I am interested in making the artifact's name also to contain > > it. > > > > > > Right now, Continuum generates artifacts named like, say, > > > artifact-1.0-20060801.123409-10.jar. Here, the number 10, I think, is > > the > > > build number. Instead of this, I was hoping that I can get the > > revision > > > number from SVN. This way, looking at the artifact name I can know > > precisely > > > where it came from. SVN does a great job of ensuring atomic commits > > and > > > maintaining revision numbers for the whole repository; it would be a > > shame > > > not to make use of that. > > > > > > To summarize, I am fine with the way SNAPSHOT builds work in general. > > All I > > > am looking for is a way to make use of the SVN revision number within > > the > > > SNAPSHOT version number. Note that for non-SNAPSHOT binaries, I *want* > > > version numbers exactly as mentioned in the POM. :-) > > > > > > Thanks, > > > Binil > > > > > > On 8/1/06, Jesse McConnell < jesse.mcconnell@gmail.com> wrote: > > > > > > > > I don't really know of a simple way to do that, there are a couple > > of > > > > factors at play here.. > > > > > > > > the tag in the pom.xml is what governs the version that is > > > > appended to the artifact for storage in the repository, and that > > > > version doesn't change with scm version numbers anyway that I know > > of > > > > (of course I could be wrong, there might be a way). > > > > > > > > If you need functionality that can map a version in a repository to > > a > > > > particular snapshot in time of the scm then I would recommend using > > > > the SNAPSHOTs setup. In these the version of your pom would be > > > > something like 1.0-SNAPSHOT and then whenever continuum deployed the > > > > snapshot it would replace that version with a timestamp. That > > > > timestamp could be turn be converted into a date that could you pass > > > > into subversion and get the checkout of source corresponding to that > > > > point in time. > > > > > > > > that is nice also in that developers using your continuum published > > > > repository don't have to do anything to get the latest releases of > > > > code into thier development environment, maven will download the > > > > latest snapshot for them. > > > > > > > > anyway, good luck! > > > > > > > > On 8/1/06, Binil Thomas wrote: > > > > > Hi all, > > > > > > > > > > I am using Continuum 1.0.3, Maven 2.0.4 & SVN . I have configured > > > > Continuum > > > > > to publish the artifacts it build into a shared repository, as > > described > > > > in > > > > > the 'Better Builds With Maven' book. I would like the revision > > number of > > > > the > > > > > SVN repository to be part of the version number of artifacts > > generated > > > > by > > > > > Continuum. Is there a simple way to achieve this? > > > > > > > > > > Thanks, > > > > > Binil > > > > > > > > > > PS: I am unsure if this question had been asked here before; I > > tried > > > > > searching the list archives and could not find the answer. > > > > > > > > > > > > > > > > > > > > > > -- > > > > jesse mcconnell > > > > jesse.mcconnell@gmail.com > > > > > > > > > > > > > > > > -- > > jesse mcconnell > > jesse.mcconnell@gmail.com > > > > ------=_Part_487_8222944.1154537426168--