Author: paul
Date: 2006-05-26 16:30:54 +0200 (Fri, 26 May 2006)
New Revision: 2211
Log:
r10755@frost: paul | 2006-05-26 08:57:56 -0500
Short utility script to de-DocBook changelog entries for
pasting into bug reports.
Added:
trunk/tools/detag.pl
Modified:
trunk/
Property changes on: trunk
___________________________________________________________________
Name: svk:merge
- 4767c598-dc10-0410-bea0-d01b485662eb:/mysqldoc-local/mysqldoc/trunk:10054
b5ec3a16-e900-0410-9ad2-d183a3acac99:/mysqldoc-local/mysqldoc/trunk:10754
bf112a9c-6c03-0410-a055-ad865cd57414:/mysqldoc-local/mysqldoc/trunk:7517
+ 4767c598-dc10-0410-bea0-d01b485662eb:/mysqldoc-local/mysqldoc/trunk:10054
b5ec3a16-e900-0410-9ad2-d183a3acac99:/mysqldoc-local/mysqldoc/trunk:10755
bf112a9c-6c03-0410-a055-ad865cd57414:/mysqldoc-local/mysqldoc/trunk:7517
Added: trunk/tools/detag.pl
===================================================================
--- trunk/tools/detag.pl (rev 0)
+++ trunk/tools/detag.pl 2006-05-26 14:30:54 UTC (rev 2211)
@@ -0,0 +1,25 @@
+#! /usr/bin/perl -w
+# vim:set ts=2 sw=2 expandtab:
+
+# detag.pl - remove <xxx>, </xxx>, <xxx/> tags, wrap result to 70 chars
+
+# Useful for filtering changelog entries containing DocBook markup
+# and rewrapping so that the result can be pasted into a bug report.
+
+# Paul DuBois
+# paul@stripped
+# 2006-05-26
+
+use strict;
+use HTML::Strip;
+use Text::Wrap;
+$Text::Wrap::columns = 70;
+
+$/ = undef;
+$_ = <>; # slurp input document as single string
+
+my $hs = HTML::Strip->new (emit_spaces => 0);
+$_ = $hs->parse ($_);
+s/\n +/ /g;
+s/^ +//g;
+print wrap ("", "", $_);
Property changes on: trunk/tools/detag.pl
___________________________________________________________________
Name: svn:executable
+ *
| Thread |
|---|
| • svn commit - mysqldoc@docsrva: r2211 - in trunk: . tools | paul | 26 May |