aboutsummaryrefslogtreecommitdiffhomepage
path: root/gen_hdr.sh
blob: 5e09f40e3303ad01435ffb97ad75bba68c8e589d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
#!/bin/sh

# This little script calls the man command to render a manual page and
# pipes the result into the gen_hdr2 program to convert the output
# into a C string literal. 

# NAME is the name of the function we are generating documentation for.
NAME=`basename $1 .doxygen`

# Render the page
nroff -man doc_src/builtin_doc/man/man1/${NAME}.1 | col -b | cat -s | sed -e '$d' | ./gen_hdr2