Paul, Thanks for you support in sorting this out -- I suspect I might have twigged it . . .
On Thu, 2009-12-17 at 09:33 -0500, Paul Speed wrote:
> In case it matters as far as evidence collection, when it worked for me
> I only had a handful of files in the src/ directory as I created it just
> for the test. My real src directory is elsewhere.
>
> It may also be important to note that prior to creating this src/
> directory the zip task would never run since it considered itself up to
> date.
I think it turns out that the actual content might have been a red
herring . . .
> I never saw an NPE in any of my testing so it's either a problem with a
> later build than what I have or your environment somehow.
I think that every example in the user guide of using Tar or Zip does so
in the context of using the Java plugin and that the Java plugin somehow
sets the default directory for all Tar and Zip tasks.
By default the destinationDir property of Tar and Zip tasks is empty
which means null and hence NPE.
> Incidentally, Hans's comments not withstanding, the syntax below is
> incorrect for your intent, I think since there is nothing associating
> the into( 'test' ) with any from()s. When I tried the blow (which
> worked, by the way) it produced a zip with only the files and no src or
> test subdirectories.
Just at the minute . . . pass :-)
I had been using whatever it was in the Gradle build -- which I had
assumed did what it was meant and implied to do -- perhaps it doesn't.
Anyway, now that I know that destinationDir has to be set explicitly
when outside the context of a Java plugin scope I can at least try some
experiment to see what doe and doesn't work.
At least I have escaped NPE :-)
The error message is fundamentally poor. Well rubbish really.
--
Russel.
=============================================================================
Dr Russel Winder Partner
xmpp: [email protected]
Concertant LLP t: +44 20 7585 2200, +44 20 7193 9203
41 Buckmaster Road, f: +44 8700 516 084 voip: sip:[email protected]
London SW11 1EN, UK m: +44 7770 465 077 skype: russel_winder
signature.asc
Description: This is a digitally signed message part
