[med-svn] [phast] 03/03: Fiddle around with specific output

Andreas Tille tille at debian.org
Wed Jun 8 14:08:45 UTC 2016


This is an automated email from the git hooks/post-receive script.

tille pushed a commit to branch master
in repository phast.

commit d5f3f5f1f07114155812190de08c06427b267a34
Author: Andreas Tille <tille at debian.org>
Date:   Wed Jun 8 16:08:23 2016 +0200

    Fiddle around with specific output
---
 debian/help2man_wrapper | 18 ++++++++++++------
 1 file changed, 12 insertions(+), 6 deletions(-)

diff --git a/debian/help2man_wrapper b/debian/help2man_wrapper
index 06d3f84..e4db512 100755
--- a/debian/help2man_wrapper
+++ b/debian/help2man_wrapper
@@ -13,11 +13,11 @@ else
     /usr/bin/help2man --name="$desc" --no-info --no-discard-stderr --version-string="${PHAST_VERSION}" --help-option='-h' $1 > $tmpout
 fi
 cat $tmpout | \
-	sed -e 's?USAGE:        ../bin/?.SH USAGE\n?' \
-	    -e 's?../bin/??' \
+	sed -e 's?USAGE:[[:space:]]\+\.\./bin/?.SH USAGE\n?' | \
+	sed -e 's?\.\./bin/??g' \
 	    -e '/^\.SH DESCRIPTION/{;N;N;N;N;s/\(.SH DESCRIPTION\n\).*DESCRIPTION:[[:space:]]*/\1/;}' \
-	    -e 's/.SS "OPTIONS:"/.SH OPTIONS/' \
-	    -e 's/^OPTIONS:/.SH OPTIONS/' \
+	    -e 's/.SS "OPTIONS:"/.SH OPTIONS/' | \
+	sed -e 's/^OPTIONS:/.SH OPTIONS/' \
 	    -e '/^.SH DESCRIPTION/{;N;s/^.SH DESCRIPTION\nPROGRAM: .*\n//;}' \
 	    -e 's/^DESCRIPTION:/.SH DESCRIPTION/' \
 	    -e 's/^EXAMPLES:/.SH EXAMPLE/' \
@@ -26,6 +26,12 @@ cat $tmpout | \
 	    -e '/^"$/d' |
 	sed -e '/^\.SH DESCRIPTION/{;N;s/^\(\.SH DESCRIPTION\)\n\.TP/\1/;}' \
 	    -e '/^\.SH DESCRIPTION/,/^\.SH SYNOPSIS/{;N;s/\n\.IP//g;}' \
-	    -e '/^\.SH DESCRIPTION/,/^\.SH SYNOPSIS/{;N;s/\n\.TP//g;}'
+	    -e '/^\.SH DESCRIPTION/,/^\.SH SYNOPSIS/{;N;s/\n\.TP//g;}' \
+  > $tmpout
+if [ "$1" = "chooseLines" ] ; then
+    cat $tmpout | \
+     	sed -e 's?\\fB\\-\w\\fR?.HP\n&?'
+else
+    cat $tmpout
+fi
 rm $tmpout
-

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-med/phast.git



More information about the debian-med-commit mailing list