4 #   cd /path/to/lx-office
 
   5 #   ./scripts/build_doc.sh
 
   9 if [[ ! -d doc ]]; then
 
  10   echo "Please run this from the installation directory."
 
  19 if [[ ! -z $1 ]] ; then
 
  22   while [[ ! -z $1 ]] ; do
 
  27         echo "Unknown parameter $1"
 
  36 dobudish=$(ls -d doc/build/dobudish* 2> /dev/null)
 
  38 if [[ -z $dobudish ]] || [[ ! -d ${dobudish} ]]; then
 
  39   echo "There's no dobudish directory inside doc/build."
 
  45 base=documents/dokumentation
 
  46 if [[ ! -d $base ]]; then
 
  47   ./generator.sh dokumentation create book
 
  52 custom=${base}/custom-cfg
 
  54 rm -rf ${input} ${custom}
 
  55 mkdir ${input} ${input}/copy_to_output ${custom}
 
  57 cp ${doc}/dokumentation.xml ${input}/
 
  58 test -d ${doc}images && cp -R ${doc}/images ${input}/copy_to_output/
 
  59 cp -R ${doc}/build/custom-cfg/* ${custom}/
 
  61 if [[ $pdf = 1 ]] ; then
 
  62   ./generator.sh dokumentation pdf
 
  63   cp ${output}/pdf/dokumentation.pdf ${doc}/Lx-Office-Dokumentation.pdf
 
  66 if [[ $html = 1 ]]; then
 
  67   ./generator.sh dokumentation html
 
  70   cp -R ${output}/html ${doc}/