From: Michael Smith Date: Sat, 5 Apr 2008 12:53:32 +0000 (+0000) Subject: deal with subjects that have linebreaks in them or that end with the revision number X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=d0e78c2eceff64556b6daff642d8805565e21cec;p=docbook-dsssl deal with subjects that have linebreaks in them or that end with the revision number --- diff --git a/contrib/tools/svn2twitter/svn2twitter b/contrib/tools/svn2twitter/svn2twitter index 4d1d8eb6a..e3ea4ff19 100755 --- a/contrib/tools/svn2twitter/svn2twitter +++ b/contrib/tools/svn2twitter/svn2twitter @@ -23,10 +23,13 @@ my $webvcsurl = shift @ARGV; my $subject = shift @ARGV; my $twitteruser = shift @ARGV; my $twitterpass = shift @ARGV; + +$subject =~ tr/\n/ /; my $revision = $subject; # parse out just the [NNNN] revision number from the Subject -$revision =~ s/^.+\[([0-9]+)\] .+$/$1/; +$revision =~ s/^.+\[([0-9]+)\].*$/$1/; +#print "$revision\n"; my $revs = SVN::Log::retrieve ($repository, $revision);