From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 1F326A0C4D for ; Mon, 6 Sep 2021 12:29:49 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id E2F4B40E32; Mon, 6 Sep 2021 12:29:48 +0200 (CEST) Received: from smtp-relay-internal-0.canonical.com (smtp-relay-internal-0.canonical.com [185.125.188.122]) by mails.dpdk.org (Postfix) with ESMTP id DC70A40E32 for ; Mon, 6 Sep 2021 12:29:47 +0200 (CEST) Received: from mail-ej1-f72.google.com (mail-ej1-f72.google.com [209.85.218.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-internal-0.canonical.com (Postfix) with ESMTPS id A328540194 for ; Mon, 6 Sep 2021 10:29:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical.com; s=20210705; t=1630924187; bh=BNSsi64O+BNs0LbywHxBaTkFXDBSDrBCz9DKB+mhD7U=; h=From:To:Cc:Subject:Date:Message-Id:MIME-Version; b=uRvPCULU8aWQw7H13rw+n/RKWVGcwcqYk984XfQZT6f2lbZgfRLFXpBT/ONYECTga BRsgEHRReEup7/uJHYk8INXM83zkUgd5duhwQLOUJKzE7pUSMbhlrMXlSkyihvZBej iniQsDZOOBcTFp0jYrYkWzmudX2KUtsL/UixNxkjHCV8qqn01CpfFbh2FKiIl/yr2Y wRMpTLObnTmZC6e/USNlD35ADvT8ndX4nxGApv+r+v9getRK79N8/qSIAXyG240lxN rDh3Swd18vX8sHRn+mSk4kVgZWtedEPhWa5RuWE3BrJLBM/60ScfbACLi9HfTQnqrv xhy9n8oD4ELgA== Received: by mail-ej1-f72.google.com with SMTP id bx10-20020a170906a1ca00b005c341820edeso2142711ejb.10 for ; Mon, 06 Sep 2021 03:29:47 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=BNSsi64O+BNs0LbywHxBaTkFXDBSDrBCz9DKB+mhD7U=; b=r/GUoUciVMufXj8sl3Q74dDPrXHzq4/kCsiWKWqRu2e6Pvj9vJZDnvW9vPEBqNU467 BVxznkYVh8TdTmuKnF8CGQhNqvqRSGwQijuog2Grd+Q/hs/t0wMwIE102iPnVEW0slme qRs52qPAG6aXRbg/MQ2Oid6GsfmXk6PzgKxHjijb8+f36+gaUSQWrPr6Eh+6mTDTDzMu OkvbFYzxUhz3uOYlQ25U4Sk5MtNxwWfEyV+Q7ijzwiK44qaV7Xznu/G2Jtqc2FBRqE9h 3zH0Dwz9AB8QQxWtm3YR6RC2a4ARfLxWWmIc5TUdJps6H1lnMqShJq/8OxoocfRltT/q zxUA== X-Gm-Message-State: AOAM530QemfX22p18FQef9l5wJ9dQk6+brIxabPG3PkxQZjjvGyjfSjD m2NRIMB3hd+Hw9hg3TYfoyPlxnPM+7yMcK8NVYJN0BXnJJp2cP8GtjsTTE/A/osNcnmyI3GWTVW qpH2Z0DeH2HBrpxzeF/hVGQOq X-Received: by 2002:aa7:d501:: with SMTP id y1mr12807991edq.6.1630924186873; Mon, 06 Sep 2021 03:29:46 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyiYAeM5i2Jen3O7qJhmWKVaZx5/cKesVT9td4BN7ZkBjHWCBsvNYhzniLJReDQefUiBvTjIw== X-Received: by 2002:aa7:d501:: with SMTP id y1mr12807976edq.6.1630924186515; Mon, 06 Sep 2021 03:29:46 -0700 (PDT) Received: from Keschdeichel.lxd ([2001:67c:1560:8007::aac:c4ad]) by smtp.gmail.com with ESMTPSA id v13sm3656144ejx.72.2021.09.06.03.29.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Sep 2021 03:29:46 -0700 (PDT) From: christian.ehrhardt@canonical.com To: stable@dpdk.org, Luca Boccassi Cc: Christian Ehrhardt Date: Mon, 6 Sep 2021 12:29:44 +0200 Message-Id: <20210906102944.692177-1-christian.ehrhardt@canonical.com> X-Mailer: git-send-email 2.32.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-stable] [PATCH] 5-make-release-commit: tolerate longer versions X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" From: Christian Ehrhardt Without this we have tool warnings and ugly headers like 19.11.10 Foo ----------- The static underlines need to adapt to the length of the string. Signed-off-by: Christian Ehrhardt --- 5-make-release-commit | 39 ++++++++++++++++++++------------------- 1 file changed, 20 insertions(+), 19 deletions(-) diff --git a/5-make-release-commit b/5-make-release-commit index 832e8e4..374154f 100755 --- a/5-make-release-commit +++ b/5-make-release-commit @@ -21,41 +21,42 @@ change_version() fi } -update_release_note() +function rstheader() { - { + msg=${1} + rchar=${2} + n=0; echo - echo "$stable_release Release Notes" - echo "---------------------" - + echo "${msg}" + printf "${rchar}%.0s" $(seq 1 ${#msg}) + # break after line plus one empty line echo - echo "$stable_release Fixes" - echo "~~~~~~~~~~~~~" echo +} + + +update_release_note() +{ + { + + rstheader "$stable_release Release Notes" "-" + + rstheader "$stable_release Fixes" "~" $GIT log --oneline v${last_release}..HEAD | cut -d ' ' -f 2- | sort | sed 's/^/* /' - echo - echo "$stable_release Validation" - echo "~~~~~~~~~~~~~~~~~~" - echo + rstheader "$stable_release Validation" "~" echo "$(cat $stable_release/validation)" if [ -e $stable_release/known_issues ]; then - echo - echo "$stable_release Known Issues" - echo "~~~~~~~~~~~~~~~~~~~~" - echo + rstheader "$stable_release Known Issues" "~" echo "$(cat $stable_release/known_issues)" fi if [ -e $stable_release/failed_list ]; then - echo - echo "$stable_release Fixes skipped and status unresolved" - echo "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~" - echo + rstheader "$stable_release Fixes skipped and status unresolved" "~" echo "$(cat $stable_release/failed_list)" fi -- 2.32.0