Re: ChangeLogs in commit messages
Sergio Durigan Junior <[email protected]>
| Newsgroups | gmane.comp.gdb.devel |
|---|---|
| Message-ID | <[email protected]> |
On Thursday, August 14 2014, Joel Brobecker wrote: >> 3. With paths but no date-and-author headers: >> >> gdb/ChangeLog: >> >> * amd64-windows-tdep.c (amd64_windows_frame_decode_insns): >> Add debug trace. > #3, since date and author are often redundant with the commit's > author. And even if not in the same, it's in the ChangeLog entry > that should be checked in as part of the commit. Also, I feel > like having those in the CL is an extra source of potential > issue (eg: if forgot to update the date), and revision logs > cannot be fixed once the commit has been pushed, whereas dates > in ChangeLog entries can. Sorry for reopening this discussion, but I would like to propose another change. I understand Joel's arguments above, and even agreed with them when I read, but I'm not so sure anymore. Yesterday Doug asked something interesting in the channel. He was trying to figure out the date when 860789c7 was pushed. From git log: commit 860789c7d5d6ef2f60e757feb21845bb230582a8 Author: Gary Benson <[email protected]> Date: Fri Aug 8 15:37:41 2014 +0100 Use exceptions and cleanups in gdbserver This commit replaces the hacky "exception" system in gdbserver with the exceptions and cleanups subsystem from GDB. Only the catch/cleanup code in what was "main" has been updated to use the new system. Other parts of gdbserver can now be converted to use TRY_CATCH and cleanups on an as-needed basis. A side-effect of this commit is that some error messages will change slightly, and in cases with multiple errors the error messages will be printed in a different order. gdb/gdbserver/ChangeLog: * server.h (setjmp.h): Do not include. (toplevel): Do not declare. (common-exceptions.h): Include. (cleanups.h): Likewise. * server.c (toplevel): Do not define. (exit_code): New static global. (detach_or_kill_for_exit_cleanup): New function. (main): New function. Original main renamed to... (captured_main): New function. * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror. However, this is not the push date; instead, this is the date Gary committed the changes in his local repository. If you go see the ChangeLog referred in the commit message, you will see that the actual push date was 2014-08-29. While I understand the reasons for git to do that, I find it a bit annoying to be "deceived" this way, and not have the push date readily available in the commit message. Maybe there's an easy way to recover this information from git (though I couldn't find it), and if there is, then disconsider my message. However, there doesn't seem to be any straightforward way to recover the push date. So, what I propose is simple: let's add the date and the author back in the ChangeLog entry that is present in the commit message. It would make things a bit easier, at least from my perspective. WDYT? Cheers, -- Sergio GPG key ID: 0x65FC5E36 Please send encrypted e-mail if possible http://sergiodj.net/