From patchwork Tue Apr 16 09:30:23 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Andreas_Bie=C3=9Fmann?= X-Patchwork-Id: 236876 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id 945112C00E6 for ; Tue, 16 Apr 2013 19:36:36 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id B4C554A1BB; Tue, 16 Apr 2013 11:36:34 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id afEeDZ+q-l+X; Tue, 16 Apr 2013 11:36:34 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 634C14A1BC; Tue, 16 Apr 2013 11:36:33 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id DBA9C4A1BC for ; Tue, 16 Apr 2013 11:36:31 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id zSqZOX97pafb for ; Tue, 16 Apr 2013 11:36:31 +0200 (CEST) X-Greylist: delayed 417 seconds by postgrey-1.27 at theia; Tue, 16 Apr 2013 11:36:29 CEST X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from mail-we0-f175.google.com (mail-we0-f175.google.com [74.125.82.175]) by theia.denx.de (Postfix) with ESMTPS id 0B6BD4A1BB for ; Tue, 16 Apr 2013 11:36:29 +0200 (CEST) Received: by mail-we0-f175.google.com with SMTP id t11so205753wey.20 for ; Tue, 16 Apr 2013 02:36:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20120113; h=x-received:from:to:cc:subject:date:message-id:x-mailer:mime-version :content-type:content-transfer-encoding; bh=oRTr+K+rDLn3Dlf3VGU+K8ypiIdnrfdaGOvw0fbeSYg=; b=Oj+pUq6izi2hNC7ugOrw2W1LO1HpWqdMWjgaG4u4sC0cArlhYjpMvtIbf+QFvsBiB3 Gr92pIv5KydqhX+lfdpCysScCahU/aZqqrf4WzULr9TdA8Ge2g5nrzQ/lV3i1trnireL PF0rUIyMFUK6l9HicTmdb82TK+cTaafBZAltlA2gvBit+TeneCyVhCjxo7qTAQAxXV7B hS5gQFtd9453WvgVFdL+em6+/6j3/xdr0oAvirYcG+O4B+T4ArLXUjMuOwHX2PWiXNZF 7stGZ9TceQolyuNahCFxLjT5E/2/0/YpPq+mfOWQIfgd54/WeKLmuUzwnECPoQvdLapG x3bg== X-Received: by 10.180.97.233 with SMTP id ed9mr17393076wib.32.1366104570905; Tue, 16 Apr 2013 02:29:30 -0700 (PDT) Received: from localhost ([2a01:198:47b:1:210:75ff:fe1a:cd1e]) by mx.google.com with ESMTPS id n2sm18253532wiy.6.2013.04.16.02.29.29 (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Tue, 16 Apr 2013 02:29:30 -0700 (PDT) From: =?UTF-8?q?Andreas=20Bie=C3=9Fmann?= To: U-Boot ML Date: Tue, 16 Apr 2013 11:30:23 +0200 Message-Id: <1366104623-14911-1-git-send-email-andreas.devel@googlemail.com> X-Mailer: git-send-email 1.7.10.4 MIME-Version: 1.0 Cc: Tom Rini Subject: [U-Boot] [PATCH] patman: fix gitutil for decorations X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.11 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de The git config parameter log.decorate is quite useful when working with git. Patman, however can not handle the decorated output when parsing the commit. To prevent this use the '--no-decorate' switch for git-log. Signed-off-by: Andreas Bießmann Cc: Tom Rini Cc: Simon Glass --- Since this is required for me to get patman working it would be great to have this trivial change in the upcoming release. tools/patman/gitutil.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tools/patman/gitutil.py b/tools/patman/gitutil.py index f485750..8b61410 100644 --- a/tools/patman/gitutil.py +++ b/tools/patman/gitutil.py @@ -39,7 +39,8 @@ def CountCommitsToBranch(): Return: Number of patches that exist on top of the branch """ - pipe = [['git', 'log', '--no-color', '--oneline', '@{upstream}..'], + pipe = [['git', 'log', '--no-color', '--oneline', '--no-decorate', + '@{upstream}..'], ['wc', '-l']] stdout = command.RunPipe(pipe, capture=True, oneline=True).stdout patch_count = int(stdout)