You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@commons.apache.org by Stefan Rufer <st...@netcetera.ch> on 2006/02/06 11:07:29 UTC

Re: patch for FileUploadBase

How To Contribute Patches To Jakarta Commons Projects

Apache projects have a fine-grained commit "culture". Therefore you can 
not commit patches to the source code directly but rather propose them on a 
mailing list. For Jakarta-Commons this is commons-dev@jakarta.apache.org 
and commons-user@jakarta.apache.org.

This is a simple "rule-of-thumb" to create a patch for a jakarta-commons 
library using Eclipse:

Install SVN support for Eclipse

     * install SVN plugin from http://subclipse.tigris.org/update

Checkout the modules you need

     * in the SVN perspective, add new repository location pointing e.g. to
       http://svn.apache.org/repos/asf/jakarta/commons (empty user and password)
     * from this location, check out your project, e.g.
       proper/fileupload/trunk as Java Project

Build path stuff

Some Apache projects do not commit eclipse project stuff, so you have to 
set up the build path on your own. E.g. add src/java and src/test as 
source folders, add junit.jar from somewhere, ...

Do code changes

     * Adhere to the code-style of the files. Do not use Ctrl-Shift-f in
       Eclipse...
     * Write tests for your changes. You will have a much better chance
       that the code gets accepted.

Submit patches

All patches are submitted to a mailing list.

     * Right-click on the changed file. Under "Team" choose "Create
       Patch..."
     * Save it somewhere and submit the patches to the mailing list
       commons-dev@jakarta.apache.org. Note that you should include the
       module name in square brackets in the subject, e.g. "[codec] bugfix
       to prevent invalid arguments during decode"

Re-Jar a module

As you probably don't want to wait that your code gets accepted ;-) you 
want to build a new JAR right away. Most projects are built using Ant 
and/or Maven. Try
   ant jar
for the fileupload module (of course you need Ant set up).


cu
Stefan


  On Mon, 30 Jan 2006, Jamay Liu wrote:

> From: Jamay Liu <ja...@gmail.com>
> To: commons-user@jakarta.apache.org
> Subject: patch for FileUploadBase
> Date: Mon, 30 Jan 2006 15:56:37 -0500
> 
> How would I go about "patching" a class (FileUploadBase) in FileUpload?
> I'm trying to use the package with Flash 8's new upload tools, but I read
> online that there is some code in that class that I need to change to make
> it work.
> Unfortunately, I don't know how to do this, so step by step directions on
> how to "patch" a class (and re-jar the package) would be much appreciated!
>
> Thanks!
>

--
Stefan Rufer | stefan.rufer@netcetera.ch
phone +41 (0)44 247 79 92 | fax +41 (0)44 247 70 75
Netcetera AG | 8040 Z�rich | Switzerland | http://netcetera.ch