Re: Property that indicates a snapshot or release build?

2014-01-20 Thread Francesco Mari
If you are using the Maven Release Plugin you can use the releaseProfiles [1] configuration option in the perform goal [2] to activate a specific profile during a release build. In that profile you can override your specific configuration. The idea is to configure your POM for snapshot builds by d

Re: Property that indicates a snapshot or release build?

2014-01-19 Thread Baptiste Mathus
+1. At least I agree I don't think there's already a property for that. Le 19 janv. 2014 22:20, "Dan Tran" a écrit : > Sounds like a candidate enhancement for build-helper-maven-plugin > > -D > > > On Sunday, January 19, 2014, Graham Leggett wrote: > > > On 19 Jan 2014, at 6:20 PM, Anders Hammar

Re: Property that indicates a snapshot or release build?

2014-01-19 Thread Dan Tran
Sounds like a candidate enhancement for build-helper-maven-plugin -D On Sunday, January 19, 2014, Graham Leggett wrote: > On 19 Jan 2014, at 6:20 PM, Anders Hammar > > wrote: > > > Don't understand. You need to, through code, get hold of the artifact > > objects. > > I am trying to get access

Re: Property that indicates a snapshot or release build?

2014-01-19 Thread Dan Tran
Sounds like a candidate enhancement for build-helper-maven-plugin -D On Sunday, January 19, 2014, Graham Leggett wrote: > On 19 Jan 2014, at 6:20 PM, Anders Hammar > > wrote: > > > Don't understand. You need to, through code, get hold of the artifact > > objects. > > I am trying to get access

Re: Property that indicates a snapshot or release build?

2014-01-19 Thread Anders Hammar
OK, then I don't know. Don't think there is a property. /Anders On Sun, Jan 19, 2014 at 5:24 PM, Graham Leggett wrote: > On 19 Jan 2014, at 6:20 PM, Anders Hammar wrote: > > > Don't understand. You need to, through code, get hold of the artifact > > objects. > > I am trying to get access to t

Re: Property that indicates a snapshot or release build?

2014-01-19 Thread Graham Leggett
On 19 Jan 2014, at 6:20 PM, Anders Hammar wrote: > Don't understand. You need to, through code, get hold of the artifact > objects. I am trying to get access to this from a property. What I need is a property that I can embed in a path inside the pom. If the artefact is a release, the property

Re: Property that indicates a snapshot or release build?

2014-01-19 Thread Anders Hammar
Don't understand. You need to, through code, get hold of the artifact objects. /Anders On Sun, Jan 19, 2014 at 5:17 PM, Graham Leggett wrote: > On 19 Jan 2014, at 5:59 PM, Anders Hammar wrote: > > > Yes, there is methods isSnapshot() and isRelease() if you get the > Artifact > > object. See [

Re: Property that indicates a snapshot or release build?

2014-01-19 Thread Graham Leggett
On 19 Jan 2014, at 5:59 PM, Anders Hammar wrote: > Yes, there is methods isSnapshot() and isRelease() if you get the Artifact > object. See [1]. > > /Anders > > [1] http://maven.apache.org/ref/3.1.1/maven-artifact/apidocs/index.html Is there a practical example anywhere of how this could be re

Re: Property that indicates a snapshot or release build?

2014-01-19 Thread Anders Hammar
Yes, there is methods isSnapshot() and isRelease() if you get the Artifact object. See [1]. /Anders [1] http://maven.apache.org/ref/3.1.1/maven-artifact/apidocs/index.html On Sun, Jan 19, 2014 at 4:43 PM, Graham Leggett wrote: > Hi all, > > Does there exist a property in maven that will indic

Property that indicates a snapshot or release build?

2014-01-19 Thread Graham Leggett
Hi all, Does there exist a property in maven that will indicate in some fashion whether the build is a snapshot build or a release build? I am aware that "-SNAPSHOT" appears in the version number, but that won't do. I'm after a variable that has one of two discrete values, one predictable value