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 EB7D1A0C45 for ; Mon, 14 Jun 2021 15:57:20 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id DFAF540DF4; Mon, 14 Jun 2021 15:57:20 +0200 (CEST) Received: from youngberry.canonical.com (youngberry.canonical.com [91.189.89.112]) by mails.dpdk.org (Postfix) with ESMTP id C90484067E for ; Mon, 14 Jun 2021 15:57:18 +0200 (CEST) Received: from mail-qt1-f198.google.com ([209.85.160.198]) by youngberry.canonical.com with esmtps (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.93) (envelope-from ) id 1lsn5a-0007c4-A1 for stable@dpdk.org; Mon, 14 Jun 2021 13:57:18 +0000 Received: by mail-qt1-f198.google.com with SMTP id b9-20020ac86bc90000b029024a9c2c55b2so5490158qtt.15 for ; Mon, 14 Jun 2021 06:57:18 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=MwNZL7c5iJQ5SjIn/fgbNVzMWkpAr5qwMy4vH2U2DJk=; b=gtAMagdHDevSamCihj021jOfmnhTgv/7JfR6G1qsdBDlFeAXaqK2vSfz8NUceL8tFt /nhzwnnN8FoXRq0n4dxx1f/TN+2or3PlItJJ2O8SEoQZISizPmLpUsTRj5lqC17rBJq3 sWIC9hrgVwbf5KnPwll1yK6cs+FT0gUN/7Ztvx3l/WYr6/SElZorxsy6ApKfkYv8JCWU pvWC/pss+omuWvNZVbUSUCYu36+GkNOPyMM6ebO4A+jwAFTXsatFC/Lm2necV3lAzdmJ KCzI0ALPiQrpWqCX/CmulcJ7hXeX98nne5XD7NKfNSoC2yTTySNrO9TVAa1l8lT/lKNX tLeQ== X-Gm-Message-State: AOAM533V/bsEtUWuJrTVlSrzi+otlQEVXt/VH51URcA3SMQcy1ck2psZ Fs4SboqKdzcINA/JziibI7YeYTSFr9DYae9PWpjojMkWVQCSGp1ms/WLoTiXs/JJG6gWrSOr1AE nfhwHPqe03BUSQIzzpDBKizG6IaLAugOPsm4DIi0L X-Received: by 2002:a05:620a:127a:: with SMTP id b26mr16380757qkl.33.1623679037422; Mon, 14 Jun 2021 06:57:17 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxWAJBu1VATIspPywNsgVOo4H5ySuq/km6lJsTguhust04BkZ2JtZLzC3sjrY5S+GQ6OVWgfR/sgcRP+RZtK08= X-Received: by 2002:a05:620a:127a:: with SMTP id b26mr16380741qkl.33.1623679037201; Mon, 14 Jun 2021 06:57:17 -0700 (PDT) MIME-Version: 1.0 References: <20210612135628.20460-1-xuemingl@nvidia.com> In-Reply-To: <20210612135628.20460-1-xuemingl@nvidia.com> From: Christian Ehrhardt Date: Mon, 14 Jun 2021 15:56:51 +0200 Message-ID: To: Xueming Li Cc: dev , Luca Boccassi , Thomas Monjalon , dpdk stable , Yuanhan Liu Content-Type: text/plain; charset="UTF-8" Subject: Re: [dpdk-stable] [PATCH 1/2] devtools: fix version pattern for fix search 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" On Sat, Jun 12, 2021 at 3:57 PM Xueming Li wrote: > > When scanning fixes from current(HEAD) branch, local tags were included > and reported as version. For example: > $ git tag --contains --merged > 20.11_backport_202010506 // user tag > v20.11 > v20.11.1 > > This patch matches DPDK officail version pattern in search, selects > the most early tag. Official tag pattern: "v." > > Fixes: 752d8e097ec1 ("scripts: show fixes with release version of bug") > Cc: Thomas Monjalon > Cc: stable@dpdk.org > > Signed-off-by: Xueming Li > --- > devtools/git-log-fixes.sh | 5 +++-- > 1 file changed, 3 insertions(+), 2 deletions(-) > > diff --git a/devtools/git-log-fixes.sh b/devtools/git-log-fixes.sh > index 210c8dcf25..5fc57da913 100755 > --- a/devtools/git-log-fixes.sh > +++ b/devtools/git-log-fixes.sh > @@ -38,12 +38,13 @@ range="$*" > # get major release version of a commit > commit_version () # > { > + local VER="v*.*" > # use current branch as history reference > local refbranch=$(git rev-parse --abbrev-ref HEAD) > - local tag=$( (git tag -l --contains $1 --merged $refbranch 2>&- || > + local tag=$( (git tag -l $VER --contains $1 --sort=creatordate --merged $refbranch 2>&- || > # tag --merged option has been introduced in git 2.7.0 > # below is a fallback in case of old git version > - for t in $(git tag -l --contains $1) ; do > + for t in $(git tag -l $VER --contains $1) ; do > git branch $refbranch --contains $t | > sed "s,.\+,$t," > done) | > -- LGTM - thanks for improving the scripts! Reviewed-by: Christian Ehrhardt > 2.25.1 > -- Christian Ehrhardt Staff Engineer, Ubuntu Server Canonical Ltd