X-Git-Url: https://git.deb.at/?a=blobdiff_plain;f=bin%2Fdebtags-xgettext;h=91111840870064d6e3c26c1ce0ef0d6c2de010ba;hb=dfec19720f8f939dca781464da850f79a5a03490;hp=a7f718b39d421fd80d8d68948b2de4e1a2a18b05;hpb=44c93c3f354ded054d8e07e77a59ee2a5ba4a9fc;p=deb%2Fpackages.git diff --git a/bin/debtags-xgettext b/bin/debtags-xgettext index a7f718b..9111184 100755 --- a/bin/debtags-xgettext +++ b/bin/debtags-xgettext @@ -18,7 +18,9 @@ sub escape { my $text = shift; $text =~ s/\\/\\\\/g; $text =~ s/"/\\"/g; - $text =~ s/\n/\\n/g; + $text =~ s/\n\s*\.\n\s?/\\n/g; + $text =~ s/\n /\\n/g; + $text =~ s/\n//g; $text =~ s/\t/\\t/g; return $text; } @@ -59,6 +61,7 @@ sub processFile { if ($long) { $long = escape($long); + $long =~ s/^\s//; push (@msgids, $long); push (@{$messages->{$long}}, $comment.", long desc", $file); }