summaryrefslogtreecommitdiff
path: root/dgit
diff options
context:
space:
mode:
authorIan Jackson <ijackson@chiark.greenend.org.uk>2019-08-10 19:22:24 +0100
committerIan Jackson <ijackson@chiark.greenend.org.uk>2019-08-11 00:09:30 +0100
commit7b8ab167436587a706db5096e8a8f49e6f4a8ab3 (patch)
tree9792679a10703c448a991f8982fddfec0c671d12 /dgit
parent73bbd10296a565a85020215448b5a001f4a94652 (diff)
dgit: vcs-git handling: Strip [...] a la Haskell Team
The final syntax of this is not yet agreed but this regexp ought to do the right thing in all reasonable cases. (Ie, no [ ] inside the [ ].) See also #932696 against policy, which is discussing the spec. Closes: #932699 Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
Diffstat (limited to 'dgit')
-rwxr-xr-xdgit1
1 files changed, 1 insertions, 0 deletions
diff --git a/dgit b/dgit
index 541e8f6..941a14b 100755
--- a/dgit
+++ b/dgit
@@ -3853,6 +3853,7 @@ sub vcs_git_url_of_ctrl ($) {
my $vcsgiturl = $ctrl->{'Vcs-Git'};
if (length $vcsgiturl) {
$vcsgiturl =~ s/\s+-b\s+\S+//g;
+ $vcsgiturl =~ s/\s+\[[^][]*\]//g;
}
return $vcsgiturl;
}