From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from omta002.cacentral1.a.cloudfilter.net (omta002.cacentral1.a.cloudfilter.net [3.97.99.33]) by sourceware.org (Postfix) with ESMTPS id CE6773858D20 for ; Wed, 5 Apr 2023 15:53:40 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org CE6773858D20 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=Shaw.ca Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=shaw.ca Received: from shw-obgw-4001a.ext.cloudfilter.net ([10.228.9.142]) by cmsmtp with ESMTP id k3CMpxH9wjvm1k5S8pmfwP; Wed, 05 Apr 2023 15:53:40 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=shaw.ca; s=s20180605; t=1680710020; bh=R4wHsn28tHXEpKAHpHeNTk2R267kBCXM0T13kzDQ5Pg=; h=Date:From:Subject:Reply-To:To:References:In-Reply-To; b=SrIiEQ3gAyCOFCdCweled1663k8XIB0jIuRG1EEBSmpdlPnrShmZhjQTqHILv5hkl yB5FDH+9Nc3PqkMK8LbSCRgUYbDwZT1PNjfZtkTHPHcyQV5xrDlJ5ApEZ0Q1sikqIQ cgQhD/OVQuRjGkh7ssVCGXcbtrsvY9+KggAF5bZDGOT3Vvfpbwv2rCp2hYZybn86oL HOnWCnpuEgUixesOZroVAtrm9ypZJRMOwu6u9s95z9lAl94d+imL+GkFubXRdrxHKj 6vmH34dNhaIYC5H/rb1FK8VsT4YKsV2beRky/mPOzI1m/KgxD8pMRRd7Y9y+EtjHoL 5jB6ZxJA9VVhg== Received: from [10.0.0.5] ([184.64.102.149]) by cmsmtp with ESMTP id k5S7pTdzsHFsOk5S7pCvIE; Wed, 05 Apr 2023 15:53:40 +0000 X-Authority-Analysis: v=2.4 cv=XZqaca15 c=1 sm=1 tr=0 ts=642d9984 a=DxHlV3/gbUaP7LOF0QAmaA==:117 a=DxHlV3/gbUaP7LOF0QAmaA==:17 a=IkcTkHD0fZMA:10 a=r4fMqdBD6jYHu9Ofgx0A:9 a=QEXdDO2ut3YA:10 Message-ID: Date: Wed, 5 Apr 2023 09:53:39 -0600 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.9.1 From: Brian Inglis Subject: Re: Newlib's .texi docs - outdated version number/date Reply-To: newlib@sourceware.org To: newlib@sourceware.org References: <2fb28796-c14d-e02a-a989-bbc0a7994399@codesourcery.com> Content-Language: en-CA Organization: Inglis In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-CMAE-Envelope: MS4xfEwXaLx+r9WTFa66K3rftQrOUAVgdMvSI9iyjibrlFW/k607yazNYKVbr5mUvxEHSLH3lP8pvjUgkXhqSqfP6hCJpK7S8t+xAW3KkUeop2ll53TZKzjq DC/81viGgvKytvyl36x8jg5yPmO3yaJx1h3ZG9nkC/7kDUwAyiZTVVquJa4BSrK/w6O1Z3pJhU003g== X-Spam-Status: No, score=-3.7 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_LOW,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On 2023-03-30 06:11, Corinna Vinschen wrote: > On Mar 30 11:16, Tobias Burnus wrote: >> On 30.03.23 11:07, Corinna Vinschen wrote: >>> On Mar 30 09:28, Tobias Burnus wrote: >>>> Someone over here stumbled over the version/date mismatch between what is shown >>>> in the libc/libm manuals - and what is the current newlib release. >>>> ... >>>> ... Thus, blindly bumping the version/date seems to be at least more >>>> consistent than not updating it at all. >>>> >>>> Thoughts? >>> Sounds good. Please send a patch in git format-patch style. >> >> Done now. > > Pushed, thanks! > > It would be nice if we could automate this... How about - there are 2 real \n in the sed commands: $ grep '@subtitle' lib[cm]/lib[cm].texi libc/libc.texi:@subtitle Full Configuration libc/libc.texi:@subtitle @code{libc} 2.5.0 libc/libc.texi:@subtitle December 2016 libm/libm.texi:@subtitle @code{libm} 2.5.0 libm/libm.texi:@subtitle December 2016 $ sed_fmt='/^\(@subtitle\s\).*20[0-9][0-9].*$/s!!\1%(creatordate:format:%F)! /^\(@subtitle\s@code{lib[cm]}\s\)[1-9]\+[-_.][0-9]\+[-_.][0-9]\+$/s!!\1%(refname:short)! /^\(@subtitle\s@code{lib[cm]}\s\)newlib-\([1-9]\+[-_.][0-9]\+[-_.][0-9]\+\)$/s!!\1\2!' $ git tag -l --format="$sed_fmt" 'newlib-[1-9][-_.].[0-9][-_.][0-9]' \ | tail -n3 | sed -f - -i lib[cm]/lib[cm].texi $ grep '@subtitle' lib[cm]/lib[cm].texi libc/libc.texi:@subtitle Full Configuration libc/libc.texi:@subtitle @code{libc} 4.3.0 libc/libc.texi:@subtitle 2023-01-20 libm/libm.texi:@subtitle @code{libm} 4.3.0 libm/libm.texi:@subtitle 2023-01-20 $ sed_fmt='/^\(@subtitle\s\).*20[0-9][0-9].*$/s!!\1%(creatordate:format:%B %Y)! /^\(@subtitle\s@code{lib[cm]}\s\)[1-9]\+[-_.][0-9]\+[-_.][0-9]\+$/s!!\1%(refname:short)! /^\(@subtitle\s@code{lib[cm]}\s\)newlib-\([1-9]\+[-_.][0-9]\+[-_.][0-9]\+\)$/s!!\1\2!' $ git tag -l --format="$sed_fmt" 'newlib-[1-9][-_.][0-9][-_.][0-9]' \ | tail -n3 | sed -f - -i lib[cm]/lib[cm].texi $ grep '@subtitle' lib[cm]/lib[cm].texi libc/libc.texi:@subtitle Full Configuration libc/libc.texi:@subtitle @code{libc} 4.3.0 libc/libc.texi:@subtitle January 2023 libm/libm.texi:@subtitle @code{libm} 4.3.0 libm/libm.texi:@subtitle January 2023 Where to put it: git hook reference-transaction("committed") with stdin matching 'ZEROID REFOID refs/tags/newlib-[1-9]\+[-_.][0-9]\+[-_.][0-9]\+', part of some release process, or in a script? Elsewhere like assuming git in doc/Makefile.inc, or hook for commit of newlib/acinclude.m4 with any line matching '^AC_DEFUN([DEF_NEWLIB_.*_VERSION]' where value ',[.*]))$' changes would seem to be more problematic. -- Take care. Thanks, Brian Inglis Calgary, Alberta, Canada La perfection est atteinte Perfection is achieved non pas lorsqu'il n'y a plus rien à ajouter not when there is no more to add mais lorsqu'il n'y a plus rien à retirer but when there is no more to cut -- Antoine de Saint-Exupéry