Glenn Morris wrote:
Please replace "write-file-hooks" with "before-save-hook".
I did that in all files maintained in Gnulib, along with files we're copying from Automake (I updated Automake), by installing the attached. Two files remain that I don't believe I have commit privileges on upstream: build-aux/texinfo.tex and doc/maintain.texi. I think Karl Berry can do those so I'll CC: him.
>From b98b09e24686fb05983ddc6156517d398d407957 Mon Sep 17 00:00:00 2001 From: Paul Eggert <egg...@cs.ucla.edu> Date: Tue, 6 Mar 2018 20:29:14 -0800 Subject: [PATCH 1/2] autoupdate --- build-aux/ar-lib | 2 +- build-aux/compile | 4 ++-- build-aux/depcomp | 4 ++-- build-aux/install-sh | 4 ++-- build-aux/mdate-sh | 4 ++-- build-aux/mkinstalldirs | 4 ++-- build-aux/texinfo.tex | 4 ++-- 7 files changed, 13 insertions(+), 13 deletions(-) diff --git a/build-aux/ar-lib b/build-aux/ar-lib index 245e6f3..0baa4f6 100755 --- a/build-aux/ar-lib +++ b/build-aux/ar-lib @@ -4,7 +4,7 @@ me=ar-lib scriptversion=2012-03-01.08; # UTC -# Copyright (C) 2010-2017 Free Software Foundation, Inc. +# Copyright (C) 2010-2018 Free Software Foundation, Inc. # Written by Peter Rosin <p...@lysator.liu.se>. # # This program is free software; you can redistribute it and/or modify diff --git a/build-aux/compile b/build-aux/compile index 0bb9d0f..99e5052 100755 --- a/build-aux/compile +++ b/build-aux/compile @@ -1,7 +1,7 @@ #! /bin/sh # Wrapper for compilers which do not understand '-c -o'. -scriptversion=2017-09-16.17; # UTC +scriptversion=2018-03-07.03; # UTC # Copyright (C) 1999-2018 Free Software Foundation, Inc. # Written by Tom Tromey <tro...@cygnus.com>. @@ -340,7 +340,7 @@ exit $ret # Local Variables: # mode: shell-script # sh-indentation: 2 -# eval: (add-hook 'write-file-hooks 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" diff --git a/build-aux/depcomp b/build-aux/depcomp index 49eb4bf..65cbf70 100755 --- a/build-aux/depcomp +++ b/build-aux/depcomp @@ -1,7 +1,7 @@ #! /bin/sh # depcomp - compile a program generating dependencies as side-effects -scriptversion=2017-09-16.17; # UTC +scriptversion=2018-03-07.03; # UTC # Copyright (C) 1999-2018 Free Software Foundation, Inc. @@ -783,7 +783,7 @@ exit 0 # Local Variables: # mode: shell-script # sh-indentation: 2 -# eval: (add-hook 'write-file-hooks 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" diff --git a/build-aux/install-sh b/build-aux/install-sh index ac159ce..5f3d36c 100755 --- a/build-aux/install-sh +++ b/build-aux/install-sh @@ -1,7 +1,7 @@ #!/bin/sh # install - install a program, script, or datafile -scriptversion=2017-09-23.17; # UTC +scriptversion=2018-03-07.03; # UTC # This originates from X11R5 (mit/util/scripts/install.sh), which was # later released in X11R6 (xc/config/util/install.sh) with the @@ -501,7 +501,7 @@ do done # Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" diff --git a/build-aux/mdate-sh b/build-aux/mdate-sh index 21247c5..8c7a590 100755 --- a/build-aux/mdate-sh +++ b/build-aux/mdate-sh @@ -1,7 +1,7 @@ #!/bin/sh # Get modification time of a file or directory and pretty-print it. -scriptversion=2017-09-22.02; # UTC +scriptversion=2018-03-07.03; # UTC # Copyright (C) 1995-2018 Free Software Foundation, Inc. # written by Ulrich Drepper <drep...@gnu.ai.mit.edu>, June 1995 @@ -220,7 +220,7 @@ echo $day $month $year # Local Variables: # mode: shell-script # sh-indentation: 2 -# eval: (add-hook 'write-file-hooks 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" diff --git a/build-aux/mkinstalldirs b/build-aux/mkinstalldirs index a31ce6d..36aa909 100755 --- a/build-aux/mkinstalldirs +++ b/build-aux/mkinstalldirs @@ -1,7 +1,7 @@ #! /bin/sh # mkinstalldirs --- make directory hierarchy -scriptversion=2016-01-11.22; # UTC +scriptversion=2018-03-07.03; # UTC # Original author: Noah Friedman <fried...@prep.ai.mit.edu> # Created: 1993-05-16 @@ -154,7 +154,7 @@ exit $errstatus # Local Variables: # mode: shell-script # sh-indentation: 2 -# eval: (add-hook 'write-file-hooks 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" diff --git a/build-aux/texinfo.tex b/build-aux/texinfo.tex index 0af2f09..ac5c1d9 100644 --- a/build-aux/texinfo.tex +++ b/build-aux/texinfo.tex @@ -3,7 +3,7 @@ % Load plain if necessary, i.e., if running under initex. \expandafter\ifx\csname fmtname\endcsname\relax\input plain\fi % -\def\texinfoversion{2018-02-24.16} +\def\texinfoversion{2018-02-12.17} % % Copyright 1985, 1986, 1988, 1990, 1991, 1992, 1993, 1994, 1995, % 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, @@ -182,7 +182,7 @@ % Hyphenation fixes. \hyphenation{ Flor-i-da Ghost-script Ghost-view Mac-OS Post-Script - ap-pen-dix bit-map bit-maps + auto-ma-ti-cal-ly ap-pen-dix bit-map bit-maps data-base data-bases eshell fall-ing half-way long-est man-u-script man-u-scripts mini-buf-fer mini-buf-fers over-view par-a-digm par-a-digms rath-er rec-tan-gu-lar ro-bot-ics se-vere-ly set-up spa-ces -- 2.7.4
>From db0b059ae4f489d0c83b785b259eb965a181d0d0 Mon Sep 17 00:00:00 2001 From: Paul Eggert <egg...@cs.ucla.edu> Date: Wed, 7 Mar 2018 00:29:38 -0800 Subject: [PATCH 2/2] maint: write-file-hooks -> before-save-hook write-file-hooks is obsolete since Emacs 22.1 (released June 2007) and it's time to use the recommended replacement. Problem reported by Glenn Morris in: https://lists.gnu.org/r/bug-gnulib/2018-03/msg00008.html * build-aux/announce-gen, build-aux/bootstrap: * build-aux/do-release-commit-and-tag, build-aux/gendocs.sh: * build-aux/git-version-gen, build-aux/gitlog-to-changelog: * build-aux/gnu-web-doc-update, build-aux/gnupload: * build-aux/move-if-change, build-aux/prefix-gnulib-mk: * build-aux/update-copyright, build-aux/useless-if-before-free: * build-aux/vc-list-files: Update hook usage for files where Gnulib is the canonical source. --- ChangeLog | 16 ++++++++++++++++ build-aux/announce-gen | 4 ++-- build-aux/bootstrap | 4 ++-- build-aux/do-release-commit-and-tag | 4 ++-- build-aux/gendocs.sh | 4 ++-- build-aux/git-version-gen | 4 ++-- build-aux/gitlog-to-changelog | 4 ++-- build-aux/gnu-web-doc-update | 4 ++-- build-aux/gnupload | 4 ++-- build-aux/move-if-change | 4 ++-- build-aux/prefix-gnulib-mk | 2 +- build-aux/update-copyright | 4 ++-- build-aux/useless-if-before-free | 4 ++-- build-aux/vc-list-files | 4 ++-- 14 files changed, 41 insertions(+), 25 deletions(-) diff --git a/ChangeLog b/ChangeLog index 8f372df..e858e18 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,19 @@ +2018-03-07 Paul Eggert <egg...@cs.ucla.edu> + + maint: write-file-hooks -> before-save-hook + write-file-hooks is obsolete since Emacs 22.1 (released June 2007) and + it's time to use the recommended replacement. + Problem reported by Glenn Morris in: + https://lists.gnu.org/r/bug-gnulib/2018-03/msg00008.html + * build-aux/announce-gen, build-aux/bootstrap: + * build-aux/do-release-commit-and-tag, build-aux/gendocs.sh: + * build-aux/git-version-gen, build-aux/gitlog-to-changelog: + * build-aux/gnu-web-doc-update, build-aux/gnupload: + * build-aux/move-if-change, build-aux/prefix-gnulib-mk: + * build-aux/update-copyright, build-aux/useless-if-before-free: + * build-aux/vc-list-files: + Update hook usage for files where Gnulib is the canonical source. + 2018-03-05 Paul Eggert <egg...@cs.ucla.edu> binary-io: pacify gcc -Wunused-parameter diff --git a/build-aux/announce-gen b/build-aux/announce-gen index e566490..eeb9071 100755 --- a/build-aux/announce-gen +++ b/build-aux/announce-gen @@ -3,7 +3,7 @@ eval '(exit $?0)' && eval 'exec perl -wS "$0" "$@"' if 0; # Generate a release announcement message. -my $VERSION = '2017-09-13 06:45'; # UTC +my $VERSION = '2018-03-07 03:46'; # UTC # The definition above must lie within the first 8 lines in order # for the Emacs time-stamp write hook (at end) to update it. # If you change this file with Emacs, please let the write hook @@ -549,7 +549,7 @@ EOF ## perl-label-offset: -2 ## perl-extra-newline-before-brace: t ## perl-merge-trailing-else: nil -## eval: (add-hook 'write-file-hooks 'time-stamp) +## eval: (add-hook 'before-save-hook 'time-stamp) ## time-stamp-start: "my $VERSION = '" ## time-stamp-format: "%:y-%02m-%02d %02H:%02M" ## time-stamp-time-zone: "UTC0" diff --git a/build-aux/bootstrap b/build-aux/bootstrap index 25920e9..92be114 100755 --- a/build-aux/bootstrap +++ b/build-aux/bootstrap @@ -1,6 +1,6 @@ #! /bin/sh # Print a version string. -scriptversion=2017-09-19.08; # UTC +scriptversion=2018-03-07.03; # UTC # Bootstrap this package from checked-out sources. @@ -1020,7 +1020,7 @@ bootstrap_epilogue echo "$0: done. Now you can run './configure'." # Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" diff --git a/build-aux/do-release-commit-and-tag b/build-aux/do-release-commit-and-tag index 18b3942..4472ff5 100755 --- a/build-aux/do-release-commit-and-tag +++ b/build-aux/do-release-commit-and-tag @@ -3,7 +3,7 @@ # controlled .prev-version file, automate the procedure by which we record # the date, release-type and version string in the NEWS file. That commit # will serve to identify the release, so apply a signed tag to it as well. -VERSION=2017-09-13.06 # UTC +VERSION=2018-03-07.03 # UTC # Note: this is a bash script (could be zsh or dash) @@ -171,7 +171,7 @@ git tag -s -m "$pkg $ver" v$ver HEAD || die 'git tag failed' # Local variables: # indent-tabs-mode: nil -# eval: (add-hook 'write-file-hooks 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "VERSION=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" diff --git a/build-aux/gendocs.sh b/build-aux/gendocs.sh index 33277d3..9d418b9 100755 --- a/build-aux/gendocs.sh +++ b/build-aux/gendocs.sh @@ -2,7 +2,7 @@ # gendocs.sh -- generate a GNU manual in many formats. This script is # mentioned in maintain.texi. See the help message below for usage details. -scriptversion=2018-01-01.00 +scriptversion=2018-03-06.19 # Copyright 2003-2018 Free Software Foundation, Inc. # @@ -497,7 +497,7 @@ $GENDOCS_TEMPLATE_DIR/gendocs_template >"$outdir/index.html" echo "Done, see $outdir/ subdirectory for new files." # Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-end: "$" diff --git a/build-aux/git-version-gen b/build-aux/git-version-gen index 8647b9e..6d073fc 100755 --- a/build-aux/git-version-gen +++ b/build-aux/git-version-gen @@ -1,6 +1,6 @@ #!/bin/sh # Print a version string. -scriptversion=2017-09-13.06; # UTC +scriptversion=2018-03-07.03; # UTC # Copyright (C) 2007-2018 Free Software Foundation, Inc. # @@ -219,7 +219,7 @@ fi printf %s "$v" # Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" diff --git a/build-aux/gitlog-to-changelog b/build-aux/gitlog-to-changelog index d8074aa..1e73f42 100755 --- a/build-aux/gitlog-to-changelog +++ b/build-aux/gitlog-to-changelog @@ -3,7 +3,7 @@ eval '(exit $?0)' && eval 'exec perl -wS "$0" "$@"' if 0; # Convert git log output to ChangeLog format. -my $VERSION = '2017-09-13 06:45'; # UTC +my $VERSION = '2018-03-07 03:47'; # UTC # The definition above must lie within the first 8 lines in order # for the Emacs time-stamp write hook (at end) to update it. # If you change this file with Emacs, please let the write hook @@ -491,7 +491,7 @@ sub git_dir_option($) # Local Variables: # mode: perl # indent-tabs-mode: nil -# eval: (add-hook 'write-file-hooks 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "my $VERSION = '" # time-stamp-format: "%:y-%02m-%02d %02H:%02M" # time-stamp-time-zone: "UTC0" diff --git a/build-aux/gnu-web-doc-update b/build-aux/gnu-web-doc-update index 12566c3..356c561 100755 --- a/build-aux/gnu-web-doc-update +++ b/build-aux/gnu-web-doc-update @@ -2,7 +2,7 @@ # Run this after each non-alpha release, to update the web documentation at # https://www.gnu.org/software/$pkg/manual/ -VERSION=2017-09-13.06; # UTC +VERSION=2018-03-07.03; # UTC # Copyright (C) 2009-2018 Free Software Foundation, Inc. @@ -202,7 +202,7 @@ $RSYNC -avP "$builddir"/doc/manual/ $tmp/$pkg/manual ) # Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "VERSION=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" diff --git a/build-aux/gnupload b/build-aux/gnupload index b8d7385..2a0bfa3 100755 --- a/build-aux/gnupload +++ b/build-aux/gnupload @@ -1,7 +1,7 @@ #!/bin/sh # Sign files and upload them. -scriptversion=2017-09-13.06; # UTC +scriptversion=2018-03-07.03; # UTC # Copyright (C) 2004-2018 Free Software Foundation, Inc. # @@ -432,7 +432,7 @@ done exit 0 # Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" diff --git a/build-aux/move-if-change b/build-aux/move-if-change index f159236..5da3eae 100755 --- a/build-aux/move-if-change +++ b/build-aux/move-if-change @@ -2,7 +2,7 @@ # Like mv $1 $2, but if the files are the same, just delete $1. # Status is zero if successful, nonzero otherwise. -VERSION='2017-09-13 06:45'; # UTC +VERSION='2018-03-07 03:47'; # UTC # The definition above must lie within the first 8 lines in order # for the Emacs time-stamp write hook (at end) to update it. # If you change this file with Emacs, please let the write hook @@ -75,7 +75,7 @@ else fi ## Local Variables: -## eval: (add-hook 'write-file-hooks 'time-stamp) +## eval: (add-hook 'before-save-hook 'time-stamp) ## time-stamp-start: "VERSION='" ## time-stamp-format: "%:y-%02m-%02d %02H:%02M" ## time-stamp-time-zone: "UTC0" diff --git a/build-aux/prefix-gnulib-mk b/build-aux/prefix-gnulib-mk index 62caca8..67b723f 100755 --- a/build-aux/prefix-gnulib-mk +++ b/build-aux/prefix-gnulib-mk @@ -230,7 +230,7 @@ sub process ($) ## cperl-extra-newline-before-brace: t ## cperl-merge-trailing-else: nil ## cperl-continued-statement-offset: 2 -## eval: (add-hook 'write-file-hooks 'time-stamp) +## eval: (add-hook 'before-save-hook 'time-stamp) ## time-stamp-start: "my $VERSION = '" ## time-stamp-format: "%:y-%02m-%02d %02H:%02M" ## time-stamp-time-zone: "UTC0" diff --git a/build-aux/update-copyright b/build-aux/update-copyright index 3bb26ab..f2fc97e 100755 --- a/build-aux/update-copyright +++ b/build-aux/update-copyright @@ -3,7 +3,7 @@ eval '(exit $?0)' && eval 'exec perl -wS -0777 -pi "$0" "$@"' if 0; # Update an FSF copyright year list to include the current year. -my $VERSION = '2018-01-04.14:48'; # UTC +my $VERSION = '2018-03-07.03:47'; # UTC # Copyright (C) 2009-2018 Free Software Foundation, Inc. # @@ -269,7 +269,7 @@ else # coding: utf-8 # mode: perl # indent-tabs-mode: nil -# eval: (add-hook 'write-file-hooks 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "my $VERSION = '" # time-stamp-format: "%:y-%02m-%02d.%02H:%02M" # time-stamp-time-zone: "UTC0" diff --git a/build-aux/useless-if-before-free b/build-aux/useless-if-before-free index 9325d07..2d4d13f 100755 --- a/build-aux/useless-if-before-free +++ b/build-aux/useless-if-before-free @@ -4,7 +4,7 @@ eval '(exit $?0)' && eval 'exec perl -wST "$0" "$@"' # Detect instances of "if (p) free (p);". # Likewise "if (p != 0)", "if (0 != p)", or with NULL; and with braces. -my $VERSION = '2017-09-13 06:45'; # UTC +my $VERSION = '2018-03-07 03:47'; # UTC # The definition above must lie within the first 8 lines in order # for the Emacs time-stamp write hook (at end) to update it. # If you change this file with Emacs, please let the write hook @@ -202,7 +202,7 @@ EOF ## Local Variables: ## mode: perl ## indent-tabs-mode: nil -## eval: (add-hook 'write-file-hooks 'time-stamp) +## eval: (add-hook 'before-save-hook 'time-stamp) ## time-stamp-start: "my $VERSION = '" ## time-stamp-format: "%:y-%02m-%02d %02H:%02M" ## time-stamp-time-zone: "UTC0" diff --git a/build-aux/vc-list-files b/build-aux/vc-list-files index 567154d..12f191b 100755 --- a/build-aux/vc-list-files +++ b/build-aux/vc-list-files @@ -2,7 +2,7 @@ # List version-controlled file names. # Print a version string. -scriptversion=2017-09-13.06; # UTC +scriptversion=2018-03-07.03; # UTC # Copyright (C) 2006-2018 Free Software Foundation, Inc. @@ -105,7 +105,7 @@ do done # Local variables: -# eval: (add-hook 'write-file-hooks 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" -- 2.7.4