File: gendoc.sh

package info (click to toggle)
whitedb 0.8.0~alpha-1
  • links: PTS
  • area: main
  • in suites: experimental
  • size: 3,344 kB
  • sloc: ansic: 33,376; javascript: 3,299; python: 790; lex: 359; java: 277; makefile: 198; sh: 164; yacc: 138; sed: 41
file content (38 lines) | stat: -rwxr-xr-x 1,212 bytes parent folder | download | duplicates (4)
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
#!/bin/sh
#
# run with ASCIIDOC_XSL=/path/to/stylesheets ./gendoc.sh [ destdir ]
#
# ASCIIDOC_XSL=/usr/share/asciidoc/docbook-xsl/ ./gendoc.sh

# default stylesheets path
[ "X${ASCIIDOC_XSL}" = "X" ] && ASCIIDOC_XSL="/etc/asciidoc/docbook-xsl"

# destination directory
DESTDIR=$1
[ "X${DESTDIR}" = "X" ] && DESTDIR=Doc

iconv -f latin1 -t utf-8 Doc/Manual.txt |\
 sed -f Doc/Manual2html.sed |\
 asciidoc -b docbook - |\
 xsltproc --nonet ${ASCIIDOC_XSL}/xhtml.xsl - > ${DESTDIR}/Manual.html

iconv -f latin1 -t utf-8 Doc/python.txt |\
 sed -f Doc/python2html.sed |\
 asciidoc -b docbook - |\
 xsltproc --nonet ${ASCIIDOC_XSL}/xhtml.xsl - > ${DESTDIR}/python.html

iconv -f latin1 -t utf-8 Doc/Tutorial.txt |\
 sed -f Doc/Tutorial2html.sed |\
 asciidoc -b docbook - |\
 xsltproc --nonet ${ASCIIDOC_XSL}/xhtml.xsl - > ${DESTDIR}/Tutorial.html

iconv -f latin1 -t utf-8 Doc/Install.txt |\
 sed -f Doc/Install2html.sed |\
 asciidoc -b docbook - |\
 xsltproc --nonet ${ASCIIDOC_XSL}/xhtml.xsl - > ${DESTDIR}/Install.html

iconv -f latin1 -t utf-8 Doc/Utilities.txt |\
 asciidoc -b docbook - |\
 xsltproc --nonet ${ASCIIDOC_XSL}/xhtml.xsl - > ${DESTDIR}/Utilities.html

# add Doxygen / PyDoc generation here as needed