1
0
Fork 0

reduce variance in generated man pages

This commit is contained in:
Jan Steemann 2016-02-25 13:48:50 +01:00
parent 51eb138c94
commit b1988c94b8
2 changed files with 4 additions and 9 deletions

View File

@ -6,7 +6,9 @@ s/^ //
/OPTIONS/s/^\(.*\)$/\.SH \1/
/EXAMPLES/s/^\(.*\)$/\.SH \1/
/FILES/s/^\(.*\)$/\.SH \1/
/AUTHOR/s/^\(.*\)$/\.SH AUTHOR/
/AUTHOR/s/^\(.*\)$/\.SH AUTHOR\
Copyright ArangoDB GmbH, Cologne, Germany\
/
/SEE ALSO/s/^\(.*\)$/\.SH \1/
s/\<OPTION\>/\.IP/g
s/\<ENDOPTION\>//g
@ -20,9 +22,3 @@ s/\<ENDEXAMPLE\>/\
/^[a-z]/s/^\(.*\)$/\.BR \1/
s/(\([1-9]\))/ "(\1), "/g
}
/AUTHOR/{
i\
a\
Copyright ArangoDB GmbH, Cologne, Germany
}

View File

@ -8,13 +8,12 @@ section=`echo $IN | sed -e 's:.*\([0-9]\):\1:'`
command=`echo $IN | sed -e 's:.*/\([^\.]*\).[0-9]:\1:'`
(
echo '<COMMAND> <SECTION> "<DATE>" "<VERSION>" "ArangoDB"'
echo '<COMMAND> <SECTION> "<VERSION>" "ArangoDB" "ArangoDB"'
cat $IN
) | sed \
-f `dirname $0`/../Documentation/Scripts/man.sed \
-e "s/<SECTION>/$section/g" \
-e "s/<COMMAND>/$command/g" \
-e "s/<DATE>/`date "+%d %b %Y"`/g" \
-e "s/<VERSION>/$VERSION/g" \
> $OUT