Ian MacLean wrote: > > Merrill Cornish wrote: > > > Felice, > > > > In the new, improved NAnt, properties now have the option of a > > readonly attirbute. Furthermore, any property set because > it appeared > > in a -D:property=value item on the script command line will > > automatically be readonly. So, you can't change in the script the > > value of a property passed in via the command line. > > > really ? When did that change come in ?
It's in the release notes-in-progress (0.85), General changes... * Overwriting of read-only properties will now result in a build failure. > It doesn't seem right > that you can't set a default in the build file and have it > overwritten by the value passed on the commandline. This is a > fairly common use case. The previous behaviour probably makes > more sense. If it's a common use case, then perhaps it should be moved into the Breaking changes section of the release notes? The previous behaviour of silently ignoring the property task if the property is read-only certainly isn't optimal, either. Silently ignoring tasks can make some bugs hard to trace. A change to the property statement to remove the breakage: <property name="junk" value="Development 1.4" unless="${property::exists('junk')}" /> The above has the addition of being somewhat self-documenting as a default, in addition to not overwriting non-readonly values of the property set in other locations in the build file. With regards to properties set on the commandline being read-only, it has always been a slight concern to me that you could break a build by specifying a property that's used internally (and expected to be non-readonly) on the commandline. I don't know of a good solution to this, though. -T Disclaimer Message: This message contains confidential information and is intended only for the individual(s) named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please immediately delete it and all copies of it from your system, destroy any hard copies of it, and notify the sender. E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. To the maximum extent permitted by law, Immersive Technologies Pty. Ltd. does not accept liability for any errors or omissions in the contents of this message which arise as a result of e-mail transmission. ------------------------------------------------------- SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media 100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33 Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift. http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285 _______________________________________________ Nant-users mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/nant-users