Harmeet,

The advantage of using patch (i.e. patch format contributions to be applied with the patch tool) is simply that it eliminates the danger of overwriting someone else's change to the same file. Quite aside from patch's ability to merge many changes automatically, it warns the user when something is wrong! This is vastly preferable to overwriting someone else's changes to the contributed source file.

I was recently the victim of a stuff up of this kind at work. It is extremely irritating to discover that a bug that you thought you had fixed has been "unfixed" by someone else!

IMHO, patch should be used wherever possible. It is part of being a responsible team member. On the other hand, in a community such as this all contributions (in whatever format) are gratefully accepted. :-)

FYI - To create a patch of the difference between your local cvs working directory and the repository execute the following cvs command from the top level working directory (e.g. the jakarta-james dir):

cvs diff -u > mycontribution.patch

The "-u" switch tells it to output diffs in unified format, which seems to be more tolerant of conflicts than (default) context diffs.

To apply the patch execute the following command from the same dir:
patch --dry-run -p0 < mycontrib.patch && patch -p0 < mycontrib.patch

This will do a test run and apply the patch only if no conflicts are found. (Prevents messy .rej files being left all over the place.) If patch complains about conflicts, you will need to resolve them manually. These conflicts should not be seen as irritating - they are saving you from having your work overwritten!

Cheers


ADK


Harmeet Bedi wrote:

The word patch is a bit overloaded. There is patch submitted by Serge and a
patch tool that helps merge diff with source. In this case 3 source files.

Anyway, just and FYI. It struck me that Noel was referring to the latter
when he mentioned 'patch'.

Harmeeet
----- Original Message -----
From: "Harmeet Bedi" <[EMAIL PROTECTED]>
To: "James Developers List" <[EMAIL PROTECTED]>
Sent: Friday, January 24, 2003 12:52 AM
Subject: Re: [PATCH] Upgrade to DnsJava 1.3.2 + revision 2 of my original
patch



----- Original Message -----
From: "Harmeet Bedi" <[EMAIL PROTECTED]>
To: "James Developers List" <[EMAIL PROTECTED]>
Sent: Friday, January 24, 2003 12:43 AM
Subject: Re: [PATCH] Upgrade to DnsJava 1.3.2 + revision 2 of my original
patch



2 years back or so when I contributed my first patches, I think I was

asked

or did both diff and full source.

I find full source is convenient and prefer that. Don't think there is

any

need to have any hard and fast rules, if a contributor can submit source
good, otherwise good too.

Serge if you can submit source good, saves one step for the person

adding

it

in.

From: "Noel J. Bergman" <[EMAIL PROTECTED]>

Do you need help with patch? Danny and I know how to use the linux

version.

I presume that Serge can tell you how to use a Windows version.

I don't think it is such a big deal. If you or Danny are around and want

to

add the patch go ahead or I'll do it over the weekend if it has not been
done.
The patch seems pretty straight forward. Noel, what sort of help did you
have in mind ? version of what ?

Noel, were you referring to patch ?
It is useful but if the person committing a patch can avoid one step it
makes a little bit easier.
Add to faq if you think patch or another tool is good information.

Harmeet



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




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

Reply via email to