--- Kev Jackson <[EMAIL PROTECTED]> wrote:

> Hm,
> 
> In the cargo code we have:
> 
> /**
>  * Remove all file in the configuration directory.
>  */
>  private void cleanConfigurationDirectory()
>  {
>      // Clean up stuff previously put in the
> temporary directory but do not
>      // remove the Cargo timestamp file
>      Delete delete = (Delete)
> getAntUtils().createAntTask("delete");
> 
>      FileSet fileSet = new FileSet();
>      fileSet.setDir(getHome());
>      fileSet.createInclude().setName("**/*");
>      fileSet.createExclude().setName(".cargo");
> 
>      // Ensure we really delete all files.
>      fileSet.setDefaultexcludes(false);
>         
>      delete.addFileset(fileSet);
>      delete.setIncludeEmptyDirs(true);
>      delete.setFailOnError(true);
>      delete.setQuiet(false);
>         
>      delete.execute();        
>  }
> 
> So there's no project being set here for the Delete
> task, unless 
> createAntTask performs some setup magic.
> 
> Matt, as you worked on the resource collections for
> the delete task, do 
> you see what's missing in this code?  It certainly
> seems that from an 
> API/programmer viewpoint, the changes to 1.7 are not
> bwc with code 
> written for 1.6.5, but I'm not sure how to go about
> 'fixing' Delete, or 
> what to suggest to the people at cargo to modify
> this code to get it to 
> work with 1.7/trunk
> 

well, obviously if I broke them it's entirely likely
they won't be alone.  Probably the easiest/most BC
thing will be some form of checking whether
(Abstract?)FileSet instances have a project set and
using the task's project if not (I think fileset
handling is separate from other ResourceCollections,
so that will work... otherwise I'll clone the
filesets).  I'll take a look in about ten hours after
I get to work.

-Matt

> I'm going to check out the 1.6.5 branch and continue
> testing on that as 
> it doesn't contain the new delete code
> 
> Thanks
> Kev
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> For additional commands, e-mail:
> [EMAIL PROTECTED]
> 
> 


__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to