From patchwork Wed May 3 15:30:13 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sean Paul X-Patchwork-Id: 9710001 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 3B10860362 for ; Wed, 3 May 2017 15:30:20 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2510F28646 for ; Wed, 3 May 2017 15:30:20 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 1980F2864A; Wed, 3 May 2017 15:30:20 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.1 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_MED,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 9235F28646 for ; Wed, 3 May 2017 15:30:19 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id BE7B66E171; Wed, 3 May 2017 15:30:17 +0000 (UTC) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mail-qk0-x22e.google.com (mail-qk0-x22e.google.com [IPv6:2607:f8b0:400d:c09::22e]) by gabe.freedesktop.org (Postfix) with ESMTPS id B598C6E171 for ; Wed, 3 May 2017 15:30:16 +0000 (UTC) Received: by mail-qk0-x22e.google.com with SMTP id u68so17990659qkd.0 for ; Wed, 03 May 2017 08:30:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=XcTGdRqyC4dvT2P2hYG41hfN6oPyCbdbq6AfQg8VsrY=; b=OtqR6h+y4yWldLF1OlVfsa87S6rzACSpCn8GrNo7K5lG7y0qJJ6RtrwqP+2W8p79Me S4ZScAAKD8BG/VnzyRDUEn9Nzo8YexnvUWX7ILga0elZ/f1pN86cDrHP8fXBI4yjb5fF Hv3D6en3Sk8SC2K+okwozqmG0rg2/1UnXUMRw= 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:in-reply-to :references; bh=XcTGdRqyC4dvT2P2hYG41hfN6oPyCbdbq6AfQg8VsrY=; b=ohkoWpMr5lH32cHX3I6mp9yqIrCff9VFKPuZ35307FLt/olDOCZqHRwjat3WL5dfUQ Y/uaDq4+Pb2Yx6ugS/TTGidXFheWVAqnrza20pkLF+f7/RfEnbGxwxIhY3TX0uzf1xN1 2ZORjByVfj82S/phnELeM5INwsWNB0oMoiXU38k9G5r9bI1AuBkjM4fVLIRjnsA0xJHr G33E4TLWNR6DKIRNbCFlhHMXb12V4f2tsPTx0u5fy4VlGR6I80xMfBXpTggFw2oRpCZk wwELHYTaNEYYgcg7jpmbqY6tiPuVj2brn/Q4+EWM1IZUVc+6kSe7rSazb2InWjtuzW1K 1V6g== X-Gm-Message-State: AN3rC/4kMgqdnJDqEFA5i2NGErmr6FfYwQG9UlAIwZQQmDshqklg0PGx 33lDb8Rz1Pkyq9by X-Received: by 10.55.67.77 with SMTP id q74mr3684696qka.185.1493825415747; Wed, 03 May 2017 08:30:15 -0700 (PDT) Received: from localhost.localdomain (99-45-70-16.lightspeed.rlghnc.sbcglobal.net. [99.45.70.16]) by smtp.gmail.com with ESMTPSA id v29sm1707441qkl.20.2017.05.03.08.30.14 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 03 May 2017 08:30:14 -0700 (PDT) From: Sean Paul To: intel-gfx@lists.freedesktop.org, daniel.vetter@intel.com, jani.nikula@linux.intel.com Date: Wed, 3 May 2017 11:30:13 -0400 Message-Id: <20170503153013.318-1-seanpaul@chromium.org> X-Mailer: git-send-email 2.13.0.rc1.294.g07d810a77f-goog In-Reply-To: <20170502182702.19899-1-seanpaul@chromium.org> References: <20170502182702.19899-1-seanpaul@chromium.org> Subject: [Intel-gfx] [maintainer-tools PATCH v3] dim: Add pull request tag template X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" X-Virus-Scanned: ClamAV using ClamSMTP Each pull request is accompanied by a summary that is stored in the git tag from which it is generated. These summaries all share the same template with headers classifying changes to UAPI, Cross-subsystem, Core, and Drivers. This patch adds this template to the tag summary automatically in dim pull-request. Changes in v2: - Tweaked the template var name s/PULL/TAG/ (Daniel) Changes in v3: - Use git tag -F- to ingest template (Jani) - Tweak naming/comments again to hopefully clarify things (Jani) Signed-off-by: Sean Paul --- dim | 25 +++++++++++++++++++++++-- dim.rst | 4 ++++ 2 files changed, 27 insertions(+), 2 deletions(-) diff --git a/dim b/dim index 8937803..baa0b38 100755 --- a/dim +++ b/dim @@ -67,6 +67,9 @@ DIM_TEMPLATE_HELLO=${DIM_TEMPLATE_HELLO:-$HOME/.dim.template.hello} # signature pull request template DIM_TEMPLATE_SIGNATURE=${DIM_TEMPLATE_SIGNATURE:-$HOME/.dim.template.signature} +# dim pull-request tag summary template +DIM_TEMPLATE_TAG_SUMMARY=${DIM_TEMPLATE_TAG_SUMMARY:-$HOME/.dim.template.tagsummary} + # # Internal configuration. # @@ -1501,6 +1504,24 @@ function dim_tag_next } +function prep_pull_tag_summary +{ + if [ -r $DIM_TEMPLATE_TAG_SUMMARY ]; then + cat $DIM_TEMPLATE_TAG_SUMMARY + else + cat <<-EOF + UAPI Changes: + + Cross-subsystem Changes: + + Core Changes: + + Driver Changes: + + EOF + fi +} + # dim_pull_request branch upstream function dim_pull_request { @@ -1533,9 +1554,9 @@ function dim_pull_request while git tag -l $tag | grep -q $tag ; do tag="$branch-$today-$((++suffix))" done - gitk "$branch@{upstream}" ^$upstream & - $DRY git tag -a $tag "$branch@{upstream}" + prep_pull_tag_summary | $DRY git tag -F- $tag "$branch@{upstream}" + $DRY git tag -a -f $tag $DRY git push $remote $tag prep_pull_mail $req_file $tag diff --git a/dim.rst b/dim.rst index 3dd19f9..10572f1 100644 --- a/dim.rst +++ b/dim.rst @@ -464,6 +464,10 @@ DIM_TEMPLATE_SIGNATURE ---------------------- Path to a file containing a signature template for pull request mails. +DIM_TEMPLATE_TAG_SUMMARY +------------------------- +Path to a file containing the template for dim pull-request tag summaries. + dim_alias_ ----------------- Make **** an alias for the subcommand defined as the value. For example,