From 0b92bd72ca6cae6190ee6b6c95449e4243597e75 Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Sat, 25 Mar 2023 22:07:19 -0700 Subject: build: run "make fetch", which updated these: Preparing to make a pre-release snapshot, update these: * build-aux/announce-gen: Update from gnulib * build-aux/gnupload: Likewise. * build-aux/texinfo.tex: Update from texinfo. --- build-aux/announce-gen | 92 +++++++++++++++++++++++++-- build-aux/gnupload | 2 +- build-aux/texinfo.tex | 166 +++++++++++++++++++++++++++++++++++-------------- 3 files changed, 206 insertions(+), 54 deletions(-) diff --git a/build-aux/announce-gen b/build-aux/announce-gen index 6bf48e1b..850619a1 100755 --- a/build-aux/announce-gen +++ b/build-aux/announce-gen @@ -35,7 +35,7 @@ eval 'exec perl -wSx "$0" "$@"' if 0; -my $VERSION = '2022-07-10 01:47'; # UTC +my $VERSION = '2023-02-26 17:15'; # 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 @@ -165,6 +165,17 @@ Print the SHA1 and SHA256 signature section for each C<@file>. =cut +# This digest function omits the "=" padding that is required by cksum, +# so add the 0..2 bytes of padding required for each of Digest's algorithms. +sub digest_file_base64_wrap ($$) +{ + my ($file, $alg) = @_; + my $h = digest_file_base64($file, $alg); + $alg =~ tr{-}{}d; + my %pad = (MD5 => 2, SHA1 => 1, SHA256 => 1, SHA384 => 0, SHA512 => 2); + return $h . '=' x $pad{$alg}; +} + sub print_checksums (@) { my (@file) = @_; @@ -176,11 +187,11 @@ sub print_checksums (@) foreach my $f (@file) { - print digest_file_hex($f, "SHA-1"), " $f\n"; - print digest_file_base64($f, "SHA-256"), " $f\n"; + print ' ', digest_file_hex ($f, "SHA-1"), " $f\n"; + print ' ', digest_file_base64_wrap ($f, "SHA-256"), " $f\n"; } - print "\nThe SHA256 checksum is base64 encoded, instead of the\n"; - print "hexadecimal encoding that most checksum tools default to.\n\n"; + print "\nVerify the base64 SHA256 checksum with cksum -a sha256 --check\n"; + print "from coreutils-9.2 or OpenBSD's cksum since 2007.\n\n"; } =item C +This is to announce $package_name-$curr_version, a $release_type release. FIXME: put comments here +EOF + + my $v0 = $prev_version; + my $v1 = $curr_version; + + (my $first_name = `git config --global user.name|cut -d' ' -f1`) + =~ m{\S} or die "no name? set user.name in ~/.gitconfig\n"; + + chomp (my $n_ci = `git rev-list "v$v0..v$v1" | wc -l`); + chomp (my $n_p = `git shortlog "v$v0..v$v1" | grep -c '^[^ ]'`); + + my $prev_release_date = `git log --pretty=%ct -1 "v$v0"`; + my $this_release_date = `git log --pretty=%ct -1 "v$v1"`; + my $n_seconds = $this_release_date - $prev_release_date; + my $time_since_prev = readable_interval $n_seconds; + my $names = `git shortlog "v$v0..v$v1"|perl -lne '/^(\\w.*):/ and print " ".\$1'`; + + print <