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 6FB8EA0C44; 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 E4B964067E; Mon, 14 Jun 2021 15:57:19 +0200 (CEST) Received: from youngberry.canonical.com (youngberry.canonical.com [91.189.89.112]) by mails.dpdk.org (Postfix) with ESMTP id C7AC84067A for ; Mon, 14 Jun 2021 15:57:18 +0200 (CEST) Received: from mail-qk1-f200.google.com ([209.85.222.200]) by youngberry.canonical.com with esmtps (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.93) (envelope-from ) id 1lsn5a-0007c0-7X for dev@dpdk.org; Mon, 14 Jun 2021 13:57:18 +0000 Received: by mail-qk1-f200.google.com with SMTP id a193-20020a3766ca0000b02903a9be00d619so25920280qkc.12 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=OqBghSDF6c09tjccbA/TWDYWkKwc8t8ozeEJKCugRKwFas6CRShn/z7RWo13g7vc1q VD3roXcgmmb0jgnonmJ3M5wNhFYLbts7wH+cIwccAcXnvE33/aq6Ejs5FEtmjNElR2mS 7vLcdD9i8PJrFKf/gj7tshQkirYd9GY9vUCT4/abB5+Uk7nEV1v8mrvi+60NDiBcKLvG 3PxC0WcnB8TNlWp25/9MfKnBdbYxa7JAhC64IITYMpTwdvrdAL5o9P8+G/s25Y0J2sCn O3Olj10UZM7dF0QBXnDfBA9ahWxuiXUUpN/DGv2UfKDJCvx5nzQbcnyIe0eJ90G1EfAr ah9w== X-Gm-Message-State: AOAM530nfgBADmX7TiymzYfyZvhQLbr5qPfOdkI6EcKW91yxSul6cdhR gpsuLsHGSfSdkoVGcV7E+lpfFh2A7Ku15Wqk0rtwTV8fCb4AaOHKY7CLDWHoJu6P9nNlFw0Khxc JKOr5vYY9LXXCEOXSVuUfueHAuosVDcIveWBj X-Received: by 2002:a05:620a:127a:: with SMTP id b26mr16380758qkl.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-dev] [PATCH 1/2] devtools: fix version pattern for fix search X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" 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