source: documentation/trunk/tutorials/generate-workshop.sh

Last change on this file was 33116, checked in by ak19, 5 years ago

The generate-workshop.sh script never used to work with GS3 before. Have now fixed it up for GS3. There's still a file, processing/manifest.xml, which needs to be hand-edited to list the sections and subsections (tutorials) that need to go into a workshop. I've not modified that manifest.xml to bring it up to speed, as Dr Bainbridge will decide on what subsections (tuts) will be covered in the current workshop and into which workshop sections (called Labs) the selected tutorials ought to get organised.

  • Property svn:executable set to *
  • Property svn:keywords set to Author Date Id Revision
File size: 1.6 KB
Line 
1#!/bin/bash
2
3if [ "$GSDLHOME" == "" ]; then
4 echo You must run \'source setup.bash\' in the top level folder of your Greenstone installation before running this script
5 exit
6fi
7
8top_dir=`pwd`
9shared_dir=`pwd`/../shared
10source_dir=`pwd`/xml-source
11processing_dir=`pwd`/processing
12output_dir=`pwd`/workshop
13
14if [ ! -d $output_dir ]; then
15 mkdir $output_dir
16fi
17
18echo "processing workshop"
19
20cd $output_dir
21split_help_doc_pl=$GSDLHOME/gli/help/splithelpdocument.pl
22if [ ! -f "$GSDLHOME/gli/help/splithelpdocument.pl" ]; then
23 split_help_doc_pl=$GSDL3SRCHOME/gli/help/splithelpdocument.pl
24fi
25
26if [ "$GSDL3SRCHOME" == "" ]; then
27 java -cp $shared_dir:$GSDLHOME/gli:$GSDLHOME/gli/classes:$GSDLHOME/perllib:$shared_dir/xalan.jar -DGSDLHOME=$GSDLHOME ApplyXSLT "" $processing_dir/xml-to-workshop.xsl $source_dir/tutorial_en.xml | perl -S $split_help_doc_pl
28 java -cp $shared_dir:$GSDLHOME/gli:$GSDLHOME/gli/classes:$GSDLHOME/perllib:$shared_dir/xalan.jar -DGSDLHOME=$GSDLHOME ApplyXSLT "" $processing_dir/xml-to-one-workshop.xsl $source_dir/tutorial_en.xml > workshop.html
29else
30 java -cp $shared_dir:$GSDLHOME/gli:$GSDLHOME/gli/classes:$GSDLHOME/perllib:$shared_dir/xalan.jar -DGSDLHOME=$GSDLHOME -DGSDL3SRCHOME=$GSDL3SRCHOME ApplyXSLT "" $processing_dir/xml-to-workshop.xsl $source_dir/tutorial_en.xml | perl -S $split_help_doc_pl
31 java -cp $shared_dir:$GSDLHOME/gli:$GSDLHOME/gli/classes:$GSDLHOME/perllib:$shared_dir/xalan.jar -DGSDLHOME=$GSDLHOME -DGSDL3SRCHOME=$GSDL3SRCHOME ApplyXSLT "" $processing_dir/xml-to-one-workshop.xsl $source_dir/tutorial_en.xml > workshop.html
32
33fi
34
35
36cd $top_dir
37
38
39
40
41
Note: See TracBrowser for help on using the repository browser.