buildr-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher Tiwald <>
Subject Limiting clean task to specific files
Date Mon, 12 Sep 2011 00:09:15 GMT
Wasn't able to find another thread about this, and I suspect it's fairly simple. Hoping someone
on this list can set me straight:

I'm trying to compile "in-place" so to speak, i.e. place the .class files right next to the
.java files that form the basis for compilation. This is quite simple in terms of  changing
the layout: Specify the custom location of target/main/classes and it works just fine. The
app packages just fine, too; it includes exactly what I've told it to and excludes everything
else. My problem arises at the clean taskā€¦ using `buildr clean` wipes out my target directory,
which also happens to contain my source files.

I can extend clean like:

clean { rm_rf _('my_sources/**.class') } 

but that doesn't do anything to change clean's default behavior (namely wiping out my new,
custom target directory). Is there a simple way to specify precisely what clean cleans and
nothing else?


View raw message