summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorpelder2006-04-07 15:38:29 (EDT)
committerpelder2006-04-07 15:38:29 (EDT)
commitab7e1975f7c59742c8963c8a846ef37eda168e0c (patch)
tree965ecbd473b1578e8b3b4f715f2fb4da5ff50c1a
parentf5330c72c2c36e38c8f1dcbf6ed57f345abd7c6c (diff)
downloadorg.eclipse.jet-ab7e1975f7c59742c8963c8a846ef37eda168e0c.zip
org.eclipse.jet-ab7e1975f7c59742c8963c8a846ef37eda168e0c.tar.gz
org.eclipse.jet-ab7e1975f7c59742c8963c8a846ef37eda168e0c.tar.bz2
Yet another try at getting java doc to work
-rw-r--r--doc/org.eclipse.jet.doc/build/antJavadoc.sh99
1 files changed, 8 insertions, 91 deletions
diff --git a/doc/org.eclipse.jet.doc/build/antJavadoc.sh b/doc/org.eclipse.jet.doc/build/antJavadoc.sh
index f9bf861..01e21fb 100644
--- a/doc/org.eclipse.jet.doc/build/antJavadoc.sh
+++ b/doc/org.eclipse.jet.doc/build/antJavadoc.sh
@@ -6,6 +6,7 @@ export PATH=${PATH}:${ANT_HOME}/bin
# The current direcotry
currentPath=`echo "$PWD/$0" | sed -e 's/\(.*\)\/.*/\1\//' | sed -e 's/^[^\/]*$//g'`
+echo "currentPath =" $currentPath
# The eclipse directory
eclipseDir=$1
@@ -28,9 +29,9 @@ function groupPackage
plugin=$1
hasToken=`grep "@plugin@" $currentPath/javadoc.xml.template`
if [ "x$hasToken" != "x" ]; then
- srcDir=$currentPath/../../plugins/$plugin/src
+ srcDir=$currentPath/../src
if [ -d "$srcDir" ]; then
- packages=`find $srcDir -type f -name '*.java' -exec grep -e '^package .*;' {} \; | sed -e 's/^package *\(.*\);/\1/' | sed -e 's/[ ]*//g' | sort | uniq | xargs | sed -e 's/ /:/g'`
+ packages=`find $srcDir -type f -name '*.java' -exec grep -e '^package .*;' {} \; | sed -e 's/^package *\(.*\);/\1/' | sed -e 's/[ \n\t\r]*//g' | sort | uniq | xargs | sed -e 's/ /:/g'`
packages=`echo $packages | sed -e 's/\//\\\\\\//g' | sed -e 's/\./\\\\\./g'`
sed -e "s/\@plugin\@/${packages}/g" $currentPath/javadoc.xml.template > $currentPath/javadoc.xml.template.tmp
@@ -44,7 +45,9 @@ groupPackage $pluginName
# Original: pluginDirs=`find $eclipseDir/plugins -name @dot -printf '%T@ %p\n' | sort -n | grep org.eclipse.emf.transaction | cut -f2 -d' ' | sed -e 's/\(\/.*\)\/.*/\1/'`
# New (eclipseDir): pluginDirs=`find $eclipseDir/plugins -name 'org.eclipse.emf.transaction*' -maxdepth 1 -type d -printf '%T@ %p\n' | sort -n | cut -f2 -d' '`
# Finds plugins in the Workspace:
-pluginDirs=`find $currentPath/../../plugins -maxdepth 1 -name "${pluginName}*" -type d -printf '%T@ %p\n' | sort -n | cut -f2 -d' '`
+pluginDirs=`find $currentPath/../.. -maxdepth 1 -name "${pluginName}*" -type d -printf '%T@ %p\n' | sort -n | cut -f2 -d' '`
+
+echo "pluginDirs =" $pluginDirs
### TODO: missing emf/sdo/xsd plugins (?) in $eclipseDir - need to copy them over or reference source (?)
### so that all classes/packages (and thus @links) can be resolved
@@ -85,94 +88,8 @@ sed -e "s/\@docjar\@/${docjar}/g" $currentPath/javadoc.xml.template.tmp > $curre
eclipseDirEsc=`echo $eclipseDir | sed -e 's/\//\\\\\//g' | sed -e 's/\./\\\\\./g'`
sed -e "s/\@eclipseDir\@/${eclipseDirEsc}/g" $currentPath/javadoc.xml.template.tmp2 > $currentPath/javadoc.xml
-# Executes the ant script
-ant -f $currentPath/javadoc.xml \
- -DdestDir="$destDir" \
- -Dclasspath="$classpath" \
- -DeclipseDir="$eclipseDir" \
- -Doverview="$currentPath/overview.html"
-
-# Clean up templates
-rm -f $currentPath/javadoc.xml.template.tmp $currentPath/javadoc.xml.template.tmp2 $currentPath/javadoc.xml
-#!/bin/sh
-# The current direcotry
-currentPath=`echo "$PWD/$0" | sed -e 's/\(.*\)\/.*/\1\//' | sed -e 's/^[^\/]*$//g'`
-
-# The eclipse directory
-eclipseDir=$1
-
-# The destination directory
-destDir=$currentPath/../references/javadoc
-
-# The plugin name
-pluginName="org.eclipse.jet"
-
-# Don't execute if the destination directory has files
-#if [ -d "$destDir" ]; then
-# exit
-#fi
-
-function groupPackage
-{
- plugin=$1
- hasToken=`grep "@plugin@" $currentPath/javadoc.xml.template`
- if [ "x$hasToken" != "x" ]; then
- srcDir=$currentPath/../../plugins/$plugin/src
- if [ -d "$srcDir" ]; then
- packages=`find $srcDir -type f -name '*.java' -exec grep -e '^package .*;' {} \; | sed -e 's/^package *\(.*\);/\1/' | sed -e 's/[ \n\t\r]*//g' | sort | uniq | xargs | sed -e 's/ /:/g'`
- packages=`echo $packages | sed -e 's/\//\\\\\\//g' | sed -e 's/\./\\\\\./g'`
-
- sed -e "s/\@plugin\@/${packages}/g" $currentPath/javadoc.xml.template > $currentPath/javadoc.xml.template.tmp
- fi
- fi
-}
-
-groupPackage $pluginName
-
-# The directory of the plugins in the order they were built
-# Original: pluginDirs=`find $eclipseDir/plugins -name @dot -printf '%T@ %p\n' | sort -n | grep org.eclipse.emf.transaction | cut -f2 -d' ' | sed -e 's/\(\/.*\)\/.*/\1/'`
-# New (eclipseDir): pluginDirs=`find $eclipseDir/plugins -name 'org.eclipse.emf.transaction*' -maxdepth 1 -type d -printf '%T@ %p\n' | sort -n | cut -f2 -d' '`
-# Finds plugins in the Workspace:
-pluginDirs=`find $currentPath/../../plugins -maxdepth 1 -name "${pluginName}*" -type d -printf '%T@ %p\n' | sort -n | cut -f2 -d' '`
-
-### TODO: missing emf/sdo/xsd plugins (?) in $eclipseDir - need to copy them over or reference source (?)
-### so that all classes/packages (and thus @links) can be resolved
-
-# All the jars in the plugins directory
-classpath=`find $eclipseDir/plugins -name "*.jar" -printf "%p:"`
-
-# Calculates the packagesets and the calls to copyDocFiles
-packagesets=""
-copydocfiles=""
-for pluginDir in $pluginDirs; do
- pluginDir=`echo $pluginDir | sed -e 's/\/runtime$//g'`
- srcDir=$pluginDir/src
- if [ -d "$srcDir" ]; then
- packagesets=$packagesets"<packageset dir=\"$srcDir\"><exclude name=\"$srcDir/**/doc-files/**\"/></packageset>"
- copydocfiles=$copydocfiles"<copyDocFiles pluginDir=\"$pluginDir\"/>"
- fi
-done
-
-# Finds the proper org.eclipse.platform.doc.isv jar
-docjar=`find $eclipseDir/plugins/ -name "org.eclipse.platform.doc.isv*.jar" -printf "%f"`
-
-if [ -f $currentPath/javadoc.xml.template ]; then
- true;
-else
- cp $currentPath/javadoc.xml.template $currentPath/javadoc.xml.template.tmp;
-fi
-
-# Replaces the token @packagesets@ in the template by the actual value
-packagesets=`echo $packagesets | sed -e 's/\//\\\\\\//g' | sed -e 's/\./\\\\\./g'`
-sed -e "s/\@packagesets\@/${packagesets}/g" $currentPath/javadoc.xml.template.tmp > $currentPath/javadoc.xml.template.tmp2
-# Replaces the token @copydocfiles@ in the template by the actual value
-copydocfiles=`echo $copydocfiles | sed -e 's/\//\\\\\\//g' | sed -e 's/\./\\\\\./g'`
-sed -e "s/\@copydocfiles\@/${copydocfiles}/g" $currentPath/javadoc.xml.template.tmp2 > $currentPath/javadoc.xml.template.tmp
-# Replaces the token @docjar@ in the template by the actual value
-sed -e "s/\@docjar\@/${docjar}/g" $currentPath/javadoc.xml.template.tmp > $currentPath/javadoc.xml.template.tmp2
-# Replaces the token @eclipseDir@ in the template by the actual value
-eclipseDirEsc=`echo $eclipseDir | sed -e 's/\//\\\\\//g' | sed -e 's/\./\\\\\./g'`
-sed -e "s/\@eclipseDir\@/${eclipseDirEsc}/g" $currentPath/javadoc.xml.template.tmp2 > $currentPath/javadoc.xml
+cat $currentPath/javadoc.xml
+echo "classpath=" $classpath
# Executes the ant script
ant -f $currentPath/javadoc.xml \