Thanks for you suggestion. Btw, Hans said, it's a bug. I've created a JIRA issue.
Etienne On 18.10.2010, at 19:44, Jason Porter wrote: > Hm, I would have thought that would work. You could conditionally set > the property by checking the properties that come in, then use 0.1 as > a default. > > Jason Porter > http://lightguard-jp.blogspot.com > http://twitter.com/lightguardjp > > Software Engineer > Open Source Advocate > > PGP key id: 926CCFF5 > PGP key available at: keyserver.net, pgp.mit.edu > > > > On Mon, Oct 18, 2010 at 02:13, Etienne Studer <[email protected]> > wrote: >> build.gradle: >> version = 0.1 >> task sample << { >> println version >> } >> >> command line: >> gradle sample -Pversion=0.5 >> >> output: >> 0.1 >> >> Regards, Etienne >> >> >> On 18.10.2010, at 05:58, Jason Porter wrote: >> >>> Depends on how you're setting it. Could you paste some code? >>> >>> Jason Porter >>> http://lightguard-jp.blogspot.com >>> http://twitter.com/lightguardjp >>> >>> Software Engineer >>> Open Source Advocate >>> >>> PGP key id: 926CCFF5 >>> PGP key available at: keyserver.net, pgp.mit.edu >>> >>> >>> >>> On Sun, Oct 17, 2010 at 04:55, Etienne Studer <[email protected]> >>> wrote: >>>> Hi >>>> >>>> When I try to call 'gradle clean build -Pversion=0.3' on a build file that >>>> specifies the version to be 0.1, the value I set on the command line via >>>> -P is not applied, hence my script uses 0.1 for the version property. >>>> >>>> Is this behavior intended? I would have expected that the command line >>>> value would override the value set in the build file. >>>> >>>> Regards, Etienne >>>> >>>> >>>> --------------------------------------------------------------------- >>>> To unsubscribe from this list, please visit: >>>> >>>> http://xircles.codehaus.org/manage_email >>>> >>>> >>>> >>> >>> --------------------------------------------------------------------- >>> To unsubscribe from this list, please visit: >>> >>> http://xircles.codehaus.org/manage_email >>> >>> >> >> Etienne Studer >> Senior Software Developer >> >> Canoo Engineering AG >> Kirschgartenstrasse 5 >> CH-4051 Basel >> >> T +41 61 228 94 44 >> F +41 61 228 94 49 >> >> [email protected] >> www.canoo.com >> >> >> > > --------------------------------------------------------------------- > To unsubscribe from this list, please visit: > > http://xircles.codehaus.org/manage_email > > Etienne Studer Senior Software Developer Canoo Engineering AG Kirschgartenstrasse 5 CH-4051 Basel T +41 61 228 94 44 F +41 61 228 94 49 [email protected] www.canoo.com --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email
