File: createmanpages

package info (click to toggle)
bamkit 0.0.1%2Bgit20170413.ccd079d-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 232 kB
  • sloc: python: 1,470; sh: 51; makefile: 11
file content (64 lines) | stat: -rwxr-xr-x 2,648 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
#!/bin/sh
MANDIR=debian/man
mkdir -p $MANDIR

VERSION=`dpkg-parsechangelog | awk '/^Version:/ {print $2}' | sed -e 's/^[0-9]*://' -e 's/-.*//' -e 's/[+~]dfsg$//'`
NAME=`grep "^Description:" debian/control | sed 's/^Description: *//' | head -n1`
PROGNAME=`grep "^Package:" debian/control | sed 's/^Package: *//' | head -n1`

AUTHOR=".SH AUTHOR\n \
This manpage was written by $DEBFULLNAME for the Debian distribution and\n \
can be used for any other usage of the program.\
"

# If program name is different from package name or title should be
# different from package short description change this here
progname=bamcleanheader.py
help2man --no-info --no-discard-stderr --help-option=" --help" \
         --name="remove illegal and malformed fields from a BAM file's header" \
            --version-string="$VERSION" ${progname} > $MANDIR/${progname}.1
echo $AUTHOR >> $MANDIR/${progname}.1

progname=bamfilterrg.py
help2man --no-info --no-discard-stderr --help-option=" --help" \
         --name="filter readgroup(s) from a BAM file" \
            --version-string="$VERSION" ${progname} > $MANDIR/${progname}.1
echo $AUTHOR >> $MANDIR/${progname}.1

progname=bamfixflags.py
help2man --no-info --no-discard-stderr --help-option=" --help" \
         --name="filter readgroup(s) from a BAM file" \
            --version-string="$VERSION" ${progname} > $MANDIR/${progname}.1
echo $AUTHOR >> $MANDIR/${progname}.1

progname=bamgroupreads.py
help2man --no-info --no-discard-stderr --help-option=" --help" \
         --name="Group BAM file by read IDs without sorting" \
            --version-string="$VERSION" ${progname} > $MANDIR/${progname}.1
echo $AUTHOR >> $MANDIR/${progname}.1

progname=bamheadrg.py
help2man --no-info --no-discard-stderr --help-option=" --help" \
         --name="Inject readgroup info" \
            --version-string="$VERSION" ${progname} > $MANDIR/${progname}.1
echo $AUTHOR >> $MANDIR/${progname}.1

progname=bamlibs.py
help2man --no-info --no-discard-stderr --help-option=" --help" \
         --name="output comma delimited string of read group IDs for each library" \
            --version-string="$VERSION" ${progname} > $MANDIR/${progname}.1
echo $AUTHOR >> $MANDIR/${progname}.1

progname=bamtofastq.py
help2man --no-info --no-discard-stderr --help-option=" --help" \
         --name="Convert a coordinate sorted BAM file to FASTQ" \
            --version-string="$VERSION" ${progname} > $MANDIR/${progname}.1
echo $AUTHOR >> $MANDIR/${progname}.1

echo "$MANDIR/*.1" > debian/manpages

cat <<EOT
Please enhance the help2man output.
The following web page might be helpful in doing so:
    http://liw.fi/manpages/
EOT