From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Paul Eggert Newsgroups: gmane.emacs.devel Subject: Re: Is it time to drop ChangeLogs? (Was: bug#21998: Run 'make change-history' on release branch) Date: Sun, 13 Mar 2016 13:06:54 -0700 Organization: UCLA Computer Science Department Message-ID: <56E5C85E.90900@cs.ucla.edu> References: <56BE7E37.3090708@cs.ucla.edu> <4hd1rw1ubr.fsf@fencepost.gnu.org> <83vb50wxhv.fsf@gnu.org> <87y49vz4cg.fsf@acer.localhost.com> <83bn6quugw.fsf@gnu.org> <83k2lbo4ba.fsf@gnu.org> <56E076EC.8040606@cs.ucla.edu> <83egbjo2c6.fsf@gnu.org> <56E0B037.6080700@cs.ucla.edu> <83pov2n8ji.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="------------090401010200040608080004" X-Trace: ger.gmane.org 1457899653 27906 80.91.229.3 (13 Mar 2016 20:07:33 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 13 Mar 2016 20:07:33 +0000 (UTC) Cc: johnw@gnu.org, emacs-devel@gnu.org, yuri.v.khan@gmail.com To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Mar 13 21:07:15 2016 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1afCIE-0008Rh-5U for ged-emacs-devel@m.gmane.org; Sun, 13 Mar 2016 21:07:14 +0100 Original-Received: from localhost ([::1]:37469 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1afCID-0007Tv-3e for ged-emacs-devel@m.gmane.org; Sun, 13 Mar 2016 16:07:13 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:42520) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1afCI9-0007Te-7D for emacs-devel@gnu.org; Sun, 13 Mar 2016 16:07:10 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1afCI8-0001dg-1d for emacs-devel@gnu.org; Sun, 13 Mar 2016 16:07:09 -0400 Original-Received: from zimbra.cs.ucla.edu ([131.179.128.68]:49210) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1afCI1-0001bx-V6; Sun, 13 Mar 2016 16:07:02 -0400 Original-Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 2E4C6160F8A; Sun, 13 Mar 2016 13:07:00 -0700 (PDT) Original-Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10032) with ESMTP id NM7cuYsDk0PA; Sun, 13 Mar 2016 13:06:59 -0700 (PDT) Original-Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 05AEA160FD5; Sun, 13 Mar 2016 13:06:59 -0700 (PDT) X-Virus-Scanned: amavisd-new at zimbra.cs.ucla.edu Original-Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id 3s_catP2t5qz; Sun, 13 Mar 2016 13:06:58 -0700 (PDT) Original-Received: from [192.168.1.9] (pool-100-32-155-148.lsanca.fios.verizon.net [100.32.155.148]) by zimbra.cs.ucla.edu (Postfix) with ESMTPSA id A90CD160F8A; Sun, 13 Mar 2016 13:06:58 -0700 (PDT) User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.6.0 In-Reply-To: <83pov2n8ji.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 131.179.128.68 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:201640 Archived-At: This is a multi-part message in MIME format. --------------090401010200040608080004 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit >> Which two languages? It should be easy to fix and I can volunteer to do >> >that. > Shell scripts and Makefiles are the two I thought of immediately. > Maybe there are more, I don't know. How about TeX and PS, for > example? We have a few of those. .ps files are hardly ever edited any more, so they're low priority. .m4 files are more important. I installed into master the attached patch, which adds support for shell, makefiles, m4, and other formats that git already supports well. Run './autogen.sh git' to use it. > Btw, the best solution would be to have these tricks added to standard > Git installation, or maybe to GNU Diff (which I think Git uses?). Why > should users need to reinvent the same wheel all the time? shell scripts and makefiles are hard to automate in a portable way, as projects use different styles. Perhaps that's why the Git developers have omitted those. --------------090401010200040608080004 Content-Type: text/x-diff; name="0001-Improve-diff-hunk-headers-when-maintaining-Emacs.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename*0="0001-Improve-diff-hunk-headers-when-maintaining-Emacs.patch" >From 571b427753f8e469f777fbc1f7d1cbe247f48840 Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Sun, 13 Mar 2016 12:20:01 -0700 Subject: [PATCH] Improve diff hunk headers when maintaining Emacs * .gitattributes: Improve diff hunk header support for makefiles, shell scripts, Ada, C, C++, Objective C, HTML, SHTML, XML, Java, Perl, PHP, Python, Ruby, and TeX, all of which are used in Emacs somewhere (sometimes just in test cases). * autogen.sh: Add regexes for makefiles and shell scripts. --- .gitattributes | 46 ++++++++++++++++++++++++++++++++++++++++++++++ autogen.sh | 5 +++++ 2 files changed, 51 insertions(+) diff --git a/.gitattributes b/.gitattributes index 5ccf9a5..13e58a8 100644 --- a/.gitattributes +++ b/.gitattributes @@ -47,6 +47,52 @@ doc/misc/texinfo.tex -whitespace=blank-at-eol *.tiff binary etc/e/eterm-color binary +# Git's builtin diff hunk header styles. +*.ada diff=ada +*.[ch] diff=cpp +*.cc diff=cpp +*.cpp diff=cpp +*.hh diff=cpp +*.for diff=fortran +*.html diff=html +*.shtml diff=html +*.xml diff=html +*.java diff=java +*.m diff=objc +*.perl diff=perl +*.pl diff=perl +*.php diff=php +*.py diff=python +*.rb diff=ruby +*.ruby diff=ruby +*.tex diff=tex + # Hooks for non-default diff hunk headers; see autogen.sh. *.el diff=elisp +*.ac diff=m4 +*.m4 diff=m4 +*.mk diff=make +*[Mm]akefile diff=make +Makefile.in diff=make +*.sh diff=shell *.texi diff=texinfo +# +# Diff hunk header special-case file names. +admin/build-configs diff=perl +admin/charsets/mapconv diff=shell +admin/diff-tar-files diff=shell +admin/make-emacs diff=perl +admin/merge-gnulib diff=shell +admin/merge-pkg-config diff=shell +admin/quick-install-emacs diff=shell +admin/update-copyright diff=shell +admin/update_autogen diff=shell +build-aux/git-hooks/commit-msg diff=shell +build-aux/git-hooks/pre-commit diff=shell +build-aux/gitlog-to-emacslog diff=shell +build-aux/make-info-dir diff=shell +build-aux/move-if-change diff=shell +build-aux/msys-to-w32 diff=shell +build-aux/update-subdirs diff=shell +lib-src/rcs2log diff=shell +/make-dist diff=shell diff --git a/autogen.sh b/autogen.sh index ac728cc..9042465 100755 --- a/autogen.sh +++ b/autogen.sh @@ -281,6 +281,11 @@ git_config () git_config diff.elisp.xfuncname \ '^\(def[^[:space:]]+[[:space:]]+([^()[:space:]]+)' +git_config 'diff.m4.xfuncname' '^((m4_)?define|A._DEFUN(_ONCE)?)\([^),]*' +git_config 'diff.make.xfuncname' \ + '^([$.[:alnum:]_].*:|[[:alnum:]_]+[[:space:]]*([*:+]?[:?]?|!?)=|define .*)' +git_config 'diff.shell.xfuncname' \ + '^([[:space:]]*[[:alpha:]_][[:alnum:]_]*[[:space:]]*\(\)|[[:alpha:]_][[:alnum:]_]*=)' git_config diff.texinfo.xfuncname \ '^@node[[:space:]]+([^,[:space:]][^,]+)' -- 2.5.0 --------------090401010200040608080004--