summaryrefslogtreecommitdiff
path: root/scripts/remove-gtkdoclink.pl
diff options
context:
space:
mode:
authorAnas Nashif <anas.nashif@intel.com>2012-11-13 12:30:55 -0800
committerAnas Nashif <anas.nashif@intel.com>2012-11-13 12:30:55 -0800
commitf251dedaa31b48f7c05a4b53c112b40ebca890ef (patch)
treed6c78a1b273417506edb030c96772c8459f5831e /scripts/remove-gtkdoclink.pl
downloadxmlsec1-f251dedaa31b48f7c05a4b53c112b40ebca890ef.tar.gz
xmlsec1-f251dedaa31b48f7c05a4b53c112b40ebca890ef.tar.bz2
xmlsec1-f251dedaa31b48f7c05a4b53c112b40ebca890ef.zip
Imported Upstream version 1.2.18upstream/1.2.18
Diffstat (limited to 'scripts/remove-gtkdoclink.pl')
-rwxr-xr-xscripts/remove-gtkdoclink.pl20
1 files changed, 20 insertions, 0 deletions
diff --git a/scripts/remove-gtkdoclink.pl b/scripts/remove-gtkdoclink.pl
new file mode 100755
index 00000000..84ab625c
--- /dev/null
+++ b/scripts/remove-gtkdoclink.pl
@@ -0,0 +1,20 @@
+#!/usr/bin/perl -w
+
+use strict;
+
+my $file;
+while ($file = shift @ARGV) {
+ print "Processing $file..\n";
+ open (IN, $file) || die "Can't open $file: $!";
+ my $entire_file;
+ while(<IN>) {
+ $entire_file = $entire_file . $_;
+ }
+ close (IN);
+ $entire_file =~ s%<GTKDOCLINK\s+HREF="([^"]*)"\s*>(.*?)</GTKDOCLINK\s*>% "<font>$2</font>" %ge;
+
+ open (OUT, ">$file") || die "Can't open $file: $!";
+ print OUT $entire_file;
+ close (OUT);
+}
+