Return-Path: Delivered-To: apmail-incubator-buildr-commits-archive@locus.apache.org Received: (qmail 50458 invoked from network); 19 Feb 2008 21:02:51 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 19 Feb 2008 21:02:51 -0000 Received: (qmail 32322 invoked by uid 500); 19 Feb 2008 21:02:46 -0000 Delivered-To: apmail-incubator-buildr-commits-archive@incubator.apache.org Received: (qmail 32301 invoked by uid 500); 19 Feb 2008 21:02:46 -0000 Mailing-List: contact buildr-commits-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: buildr-dev@incubator.apache.org Delivered-To: mailing list buildr-commits@incubator.apache.org Received: (qmail 32292 invoked by uid 99); 19 Feb 2008 21:02:46 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 19 Feb 2008 13:02:46 -0800 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.3] (HELO eris.apache.org) (140.211.11.3) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 19 Feb 2008 21:02:08 +0000 Received: by eris.apache.org (Postfix, from userid 65534) id D30EC1A9832; Tue, 19 Feb 2008 13:02:28 -0800 (PST) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r629229 - /incubator/buildr/trunk/doc/pages/packaging.textile Date: Tue, 19 Feb 2008 21:02:28 -0000 To: buildr-commits@incubator.apache.org From: assaf@apache.org X-Mailer: svnmailer-1.0.8 Message-Id: <20080219210228.D30EC1A9832@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: assaf Date: Tue Feb 19 13:02:27 2008 New Revision: 629229 URL: http://svn.apache.org/viewvc?rev=629229&view=rev Log: Added documentation for clean method Modified: incubator/buildr/trunk/doc/pages/packaging.textile Modified: incubator/buildr/trunk/doc/pages/packaging.textile URL: http://svn.apache.org/viewvc/incubator/buildr/trunk/doc/pages/packaging.textile?rev=629229&r1=629228&r2=629229&view=diff ============================================================================== --- incubator/buildr/trunk/doc/pages/packaging.textile (original) +++ incubator/buildr/trunk/doc/pages/packaging.textile Tue Feb 19 13:02:27 2008 @@ -87,8 +87,12 @@ Other than that, @package :jar@ includes the contents of the compiler's target directory and resources, which most often is exactly what you intend it to do. If you want to include other files in the JAR, instead or in addition, you can -do so using the @include@ and @exclude@ methods. We'll tell you more about -them when we talk about "Packaging Zips":#packaging_zips. +do so using the @include@ and @exclude@ methods. If you do not want the target +directory included in your JAR, simply call the @clean@ method on it. + +{{{!ruby +package(:jar).clean.include( only_these_files ) +}}} h2. Packaging WARs @@ -222,6 +226,10 @@ @target/classes@, it's still working on the project definition, and has yet to compile anything. Since @target/classes@ may be empty, may not even exist, it uses @:as=>'.'@. + +If you need to get rid of all the included files, call the @clean@ method. +Some packaging types default to adding various files and directories, for +example, JAR packaging will include all the compiled classes and resources. You can also merge two ZIP files together, expanding the content of one ZIP into the other. For example: