ChangeLogs

Daniel J Sebald daniel.sebald at ieee.org
Tue Jan 6 00:21:42 CST 2009


Jaroslav Hajek wrote:
> On Tue, Jan 6, 2009 at 6:13 AM, Daniel J Sebald <daniel.sebald at ieee.org> wrote:
[snip]
>>This is the one disadvantage of putting ChangeLog hunks in the patch file.
>> They are almost always rejected because some other entry has already been
>>placed at the top.  Anyone know of a command line switch to make diff force
>>the hunk to be at the top when patched?
>>
> 
> 
> No switch, AFAIK. But I've created a patch for Mercurial that accomplishes this
> (or handles 99% cases): If a change to a ChangeLog file is detected that only
> consists of prepended lines, the diff is done without context (so that
> the hunk is
> always prepended). Adjusting the date would be nontrivial, however.

Well, in that case Mercurial also records the date applied, I would think (hope).  I'm in ChangeLog frame of mind, hence reasoning as below:


>>The patch date should be the date the patch was applied, not the date it was
>>created, in my opinion.
>>
> 
> 
> Maybe, but that's way more complicated. Moreover, what if the patch is
> transplanted
> later to another repo? Should the date of the ChangeLog entries be updated?
> Much more work.

I'd have to think about that one.  But the advantage of organizing by date patched is that when one knows roughly when something stopped working s/he can quickly surmise what may have changed to cause the problem.


[snip]
>>3) Contributors who don't check in stuff can place a ChangeLog entry as a
>>hunk in the patch file.
>>
> 
> 
> Well, you can place the changelog entry in a mercurial patch. Still,
> there's one entry
> per patch, not per directory, so that's a minor drawback.

Good point.

Dan


More information about the Octave-maintainers mailing list