summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorJohn Beppu2001-02-23 16:15:34 +0000
committerJohn Beppu2001-02-23 16:15:34 +0000
commitdf1e9daf3032a86547f10ba9010d55e2c0a8cede (patch)
treee10ac661d3240f3e3314f44447988d9be57db40d /docs
parented0d958c3eaa5f08a8aa9066c666b472b83cbc0b (diff)
downloadbusybox-df1e9daf3032a86547f10ba9010d55e2c0a8cede.zip
busybox-df1e9daf3032a86547f10ba9010d55e2c0a8cede.tar.gz
This one should be able to deal with the USAGE macros a little
more robustly. I also blow away any USAGE_NOT_\w+ macros.
Diffstat (limited to 'docs')
-rwxr-xr-xdocs/autodocifier.pl9
1 files changed, 6 insertions, 3 deletions
diff --git a/docs/autodocifier.pl b/docs/autodocifier.pl
index 1a50cd5..1f8cdc3 100755
--- a/docs/autodocifier.pl
+++ b/docs/autodocifier.pl
@@ -21,8 +21,9 @@ sub continuation {
# regex && eval away unwanted strings from documentation
sub beautify {
my $text = shift;
- $text =~ s/USAGE_\w+\([\s]*?(".*?").*?\)/$1/sg;
- $text =~ s/"[\s]*"//sg;
+ $text =~ s/USAGE_NOT\w+\(.*?"\s*\)//sxg;
+ $text =~ s/USAGE_\w+\(\s*?(.*?)"\s*\)/$1"/sxg;
+ $text =~ s/"\s*"//sg;
my @line = split("\n", $text);
$text = join('',
map { eval }
@@ -35,6 +36,8 @@ sub beautify {
}
@line
);
+ print STDERR "-- d\n";
+ print STDERR $text;
return $text;
}
@@ -179,4 +182,4 @@ John BEPPU <beppu@lineo.com>
=cut
-# $Id: autodocifier.pl,v 1.5 2001/02/23 13:04:39 beppu Exp $
+# $Id: autodocifier.pl,v 1.6 2001/02/23 16:15:34 beppu Exp $