From: hickert Date: Mon, 6 Dec 2010 07:52:44 +0000 (+0000) Subject: Removed help generation X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=d778dcb5bc3b92a6e9ad2d86b47623ccc0ba8299;p=gosa.git Removed help generation git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@20522 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-core/update-gosa b/gosa-core/update-gosa index 13f2f78e5..7e65804a7 100755 --- a/gosa-core/update-gosa +++ b/gosa-core/update-gosa @@ -209,58 +209,6 @@ function rescan_i18n() } -function rescan_guide() -{ - $master_guide= "doc/guide.xml"; - echo "Updating Online Help Index...\n"; - $master_guide_content="\n". - "\n\n". - "\n\n". - "\n". - "\n"; - - $guide= 'doc/core/guide.xml'; - if(file_exists($guide) && is_readable($guide)) { - $master_guide_content.= file_get_contents($guide); - } - - if(file_exists('doc/plugins')) { - $plugins= scandir('doc/plugins'); - foreach($plugins as $key => $plugin) { - if($plugin != '.' && $plugin != '..') { - if(is_dir('doc/plugins/'.$plugin)) { - $guide= 'doc/plugins/'.$plugin.'/guide.xml'; - if(file_exists($guide) && is_readable($guide)) { - $master_guide_content.= file_get_contents($guide); - } - } - } - } - } - - $master_guide_content.= ""; - - $master_guide_content= preg_replace("/[ \t][ \t]*/", " ", $master_guide_content); - - if((file_exists($master_guide) && is_writable($master_guide)) || is_writable('doc')) { - file_put_contents($master_guide, $master_guide_content); - } - -} - - function parse_ini($file) { global $description, $provides, $depends, $versions, $conflicts; @@ -475,7 +423,6 @@ function install_plugin($file) /* Update caches */ rescan_classes(); rescan_i18n(); - rescan_guide(); } @@ -533,7 +480,6 @@ function remove_plugin($name) /* Update caches */ rescan_classes(); rescan_i18n(); - rescan_guide(); } @@ -781,7 +727,6 @@ $description= $provides= $depends= $versions= $conflicts= array(); if ($argc < 2){ rescan_classes(); rescan_i18n(); - rescan_guide(); foreach (get_themes() as $theme) { rescan_images(GOSA_HOME."/html", $theme); } diff --git a/gosa-core/update-online-help b/gosa-core/update-online-help deleted file mode 100755 index cb3fd98ac..000000000 --- a/gosa-core/update-online-help +++ /dev/null @@ -1,134 +0,0 @@ -#!/bin/bash - -# Defaults for Debian -CNV=`pwd`/contrib/latex2html -LYX=lyx - -# Sanity checks -if [ ! -d doc/core ]; then - echo "Can't find usable core documentation structure - aborting" - exit 1 -fi - -# Commands present? -for cmd in $CNV $LYX; do - if [[ ! `which $cmd` ]]; then - echo "Can't find executable for '$cmd' - aborting" - exit 2 - fi -done - -# Create guide.xml -cat << EOF > doc/guide.xml - - - - - - - -EOF - -echo -en "Generating doc/guide.xml..." -# core guide.xml -pushd . &> /dev/null -cd doc/core -cat < guide.xml >> ../guide.xml -popd &> /dev/null - -# plugins guide.xml -pushd . &> /dev/null -if [ -d doc/plugins ]; then - cd doc/plugins - for plugin in *; do - [ -r $plugin/guide.xml ] && cat < $plugin/guide.xml >> ../guide.xml - done -fi -popd &> /dev/null - -echo -en "\n" >> doc/guide.xml -sed -i s/"[ \t][ \t]*"/" "/g doc/guide.xml -echo -en " done.\n" - -# Core help -echo -en "Processing core\n" -pushd . &> /dev/null -cd doc/core -for lang in *; do - [ ! -d "$lang" ] && continue - - pushd . &> /dev/null - echo -en "\tProcessing language $lang...\n" - cd $lang/lyx-source - - for source in $(find . -name \*.lyx -exec basename {} \;); do - echo -en "\t\tProcessing $source..." - echo -en " tex" - $LYX -e latex $source &> /dev/null - d=../html/${source%%\.*}/ - [ -d $d ] || mkdir -p $d && rm -r $d/* &> /dev/null - echo -en " html" - $CNV -no_navigation -dir $d ${source%%\.*}.tex &> /dev/null - echo -en " cleanup" - rm images/*.eps &> /dev/null - rm ${source%%\.lyx}.tex &> /dev/null - echo -en " done.\n" - continue - done - popd &> /dev/null -done - -popd &> /dev/null - -# Plugin help -pushd . &> /dev/null -if [ -d doc/plugins ]; then - cd doc/plugins - - for plugin in *; do - pushd . &> /dev/null - echo -en "Processing $plugin\n" - cd $plugin - for lang in *; do - [ ! -d "$lang" ] && continue - - pushd . &> /dev/null - echo -en "\tProcessing language $lang...\n" - cd $lang/lyx-source - - for source in $(find . -name \*.lyx -exec basename {} \;); do - echo -en "\t\tProcessing $source..." - echo -en " tex" - $LYX -e latex $source &> /dev/null - d=../html/${source%%\.*}/ - [ -d $d ] || mkdir -p $d && rm -r $d/* &> /dev/null - echo -en " html" - $CNV -no_navigation -dir $d ${source%%\.*}.tex &> /dev/null - echo -en " cleanup" - rm images/*.eps &> /dev/null - rm ${source%%\.lyx}.tex &> /dev/null - echo -en " done.\n" - continue - done - popd &> /dev/null - done - popd &> /dev/null - done - -fi -popd &> /dev/null -echo -exit 0