Return-Path: Delivered-To: apmail-maven-users-archive@www.apache.org Received: (qmail 28983 invoked from network); 26 Oct 2010 00:59:19 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 26 Oct 2010 00:59:18 -0000 Received: (qmail 18535 invoked by uid 500); 26 Oct 2010 00:59:16 -0000 Delivered-To: apmail-maven-users-archive@maven.apache.org Received: (qmail 18455 invoked by uid 500); 26 Oct 2010 00:59:16 -0000 Mailing-List: contact users-help@maven.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Maven Users List" Reply-To: "Maven Users List" Delivered-To: mailing list users@maven.apache.org Received: (qmail 18447 invoked by uid 99); 26 Oct 2010 00:59:16 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 26 Oct 2010 00:59:16 +0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests=FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of farhang@gmail.com designates 209.85.161.43 as permitted sender) Received: from [209.85.161.43] (HELO mail-fx0-f43.google.com) (209.85.161.43) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 26 Oct 2010 00:59:11 +0000 Received: by fxm19 with SMTP id 19so832801fxm.30 for ; Mon, 25 Oct 2010 17:58:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:content-type; bh=idbUOHSSMjWhWgMWPOEqOSSpyOlBouhuPoV6vhTirmU=; b=qycus4O9tTnPwOGP0dtTmjUtUqQJPAC+SdjJReMafkGwrmnUTwJBat+vTRnMq3CClv /h0VfFspYHdxbCznl5dLFxJuor8H/6Pw9qKd5d4K81RnX3TQ0XoN6CKhzQnzdzQFJubK OYWZAXO93wUjJLz2MH80ohAh8754aYMpOUXjA= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; b=XMyNctstOfmfS5zfh/SD1GTl3iIR6q6gPwAYEVOdQBLX5xwwcXtL7GYu9Q8FRqjfIy 1BC7SAg5XIPR2K5OYJIUz8IoXA/FRO/nS5jTqjujRwVoUsSgP2KZIJrdm6pqA1VV2Coz Nq9qmqghPXfSQ+ro+mQLo8AIopn8QPSA9tnAg= MIME-Version: 1.0 Received: by 10.239.163.144 with SMTP id p16mr1541020hbd.173.1288054729047; Mon, 25 Oct 2010 17:58:49 -0700 (PDT) Received: by 10.239.187.136 with HTTP; Mon, 25 Oct 2010 17:58:48 -0700 (PDT) In-Reply-To: References: Date: Mon, 25 Oct 2010 18:58:48 -0600 Message-ID: Subject: Re: avoiding dependency version number duplication From: Babak Farhang To: Maven Users List Content-Type: text/plain; charset=ISO-8859-1 > Can you explain the "transformed pom" point? Perhaps I'm not using the correct terminology, but what I meant was that I looked at the pom in my local repo after I mvn install'ed it, and it still contains the literal ${..} string where there should have been the version number. Babak On Mon, Oct 25, 2010 at 6:35 PM, Paul Benedict wrote: > Can you explain the "transformed pom" point? I believe Justin's > approach and "my" approach are identical -- all you are doing is > delaying the version resolution until you declare the dependency. > Anyway, let me know how it works out. > > Paul > > On Mon, Oct 25, 2010 at 7:03 PM, Babak Farhang wrote: >> Paul's approach (using properties defined in the parent pom) is in >> fact what I've been trying. Trouble is, the transformed pom still has >> "${spring.version}", not the *value* it should resolve to. From a >> practical standpoint, this should break transitive dependencies when >> someone includes my project (artifact) as a dependency. >> >> Justin's approach using the element sounds more >> promising. I'll report back when I've played it with it more.. >> >> Thank you all! >> -Babak >> >> On Mon, Oct 25, 2010 at 12:49 PM, Paul Benedict wrote: >>> >>> 2.5.6 >>> >>> >>> Then for your dependency versions, specify ${spring.version} >>> >>> For more information: >>> http://docs.codehaus.org/display/MAVENUSER/MavenPropertiesGuide >>> >>> Paul >> >> >> >> On Mon, Oct 25, 2010 at 12:49 PM, Justin Edelson >> wrote: >>> Use a property and/or dependency management in a shared parent POM. >>> Spring has multiple modules, so it is frequently useful to store the >>> common version for all modules in a single property and then specify >>> each relevant module in a dependencyManagement element. >>> >>> Justin >> >> >> >> >>> >>> On Mon, Oct 25, 2010 at 1:45 PM, Babak Farhang wrote: >>>> Hi everyone, >>>> >>>> Say I have a number of modules that share a dependency on Spring. I'd >>>> like to centralize the version number of the Spring library that I'm >>>> using, that is, the version these modules depend on. I.e. I don't want >>>> the version number of the Spring dependency to be duplicated across >>>> many pom files. What's the "maven way" for doing this? >>>> >>>> -Babak >>>> >>>> --------------------------------------------------------------------- >>>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org >>>> For additional commands, e-mail: users-help@maven.apache.org >>>> >>>> >>> >>> --------------------------------------------------------------------- >>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org >>> For additional commands, e-mail: users-help@maven.apache.org >>> >>> >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org >> For additional commands, e-mail: users-help@maven.apache.org >> >> > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org > For additional commands, e-mail: users-help@maven.apache.org > > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@maven.apache.org For additional commands, e-mail: users-help@maven.apache.org