control: tag -1 +patch Hello,
On Sat 06 Jul 2019 at 11:49PM +01, Ian Jackson wrote: > zealot:example> git-deborig --just-print | sed 's/^/stdout: /'; echo > ${PIPESTATUS[*]} > stdout: upstream/1.0 > stdout: ../example_1.0.orig.tar.xz > stdout: git -c 'tar.tar.xz.command=xz -c' archive '--prefix=example-1.0/' -o > ../example_1.0.orig.tar.xz upstream/1.0 > 0 0 > zealot:example> git-tag UPSTREAM-1.0 upstream/1.0 > zealot:example> git-tag -d upstream/1.0 > Deleted tag 'upstream/1.0' (was 5f40faf) > zealot:example> git-deborig --just-print | sed 's/^/stdout: /'; echo > ${PIPESTATUS[*]} > stdout: couldn't find any of the following tags: 1.0, v1.0, upstream/1.0 > stdout: tell me a tag or branch head to make an orig.tar from: git deborig > --just-print COMMITTISH > 1 0 > zealot:example> > > Expected behaviour would be to print the error message to stderr and > nothing to stdout. Patch attached & posted to <https://salsa.debian.org/debian/devscripts/merge_requests/134>. -- Sean Whitton
From 39549240a7c2f23c14aec7036148ee10c02e7d98 Mon Sep 17 00:00:00 2001 From: Sean Whitton <spwhit...@spwhitton.name> Date: Sat, 20 Jul 2019 08:38:06 +0100 Subject: [PATCH] git-deborig: print to stderr, not stdout, when appropriate Closes: #931509 Reported-by: Ian Jackson <ijack...@chiark.greenend.org.uk> --- debian/changelog | 1 + scripts/git-deborig.pl | 8 ++++---- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/debian/changelog b/debian/changelog index 59e6d6b8..5d0105a8 100644 --- a/debian/changelog +++ b/debian/changelog @@ -58,6 +58,7 @@ devscripts (2.19.6) UNRELEASED; urgency=medium [ Sean Whitton ] * git-deborig: + New --just-print-tag-names option. Closes: #931180; MR: !131 + + Print to stderr, not stdout, when appropriate. Closes: #931509; MR: !134 -- Mattia Rizzolo <mat...@debian.org> Tue, 09 Jul 2019 14:48:19 +0200 diff --git a/scripts/git-deborig.pl b/scripts/git-deborig.pl index 78b6afc5..fd5a166d 100755 --- a/scripts/git-deborig.pl +++ b/scripts/git-deborig.pl @@ -209,15 +209,15 @@ if ($user_ref) { # User told us the tag/branch to archive # If there is only one candidate version tag, we're good to go. # Otherwise, let the user know they can tell us which one to use if (scalar @version_tags > 1) { - print "tags ", join(", ", @version_tags), + print STDERR "tags ", join(", ", @version_tags), " all exist in this repository\n"; - print + print STDERR "tell me which one you want to make an orig.tar from: $orig_args TAG\n"; exit 1; } elsif (scalar @version_tags < 1) { - print "couldn't find any of the following tags: ", + print STDERR "couldn't find any of the following tags: ", join(", ", @candidate_tags), "\n"; - print + print STDERR "tell me a tag or branch head to make an orig.tar from: $orig_args COMMITTISH\n"; exit 1; } else { -- 2.20.1
signature.asc
Description: PGP signature