stefano 2003/02/23 07:15:29
Added: . cocoon.bat Log: the new cocoon launch system that uses Forehead as a bootstrapping tool (unix version coming up next) Revision Changes Path 1.1 xml-cocoon2/cocoon.bat Index: cocoon.bat =================================================================== @echo off :: ----------------------------------------------------------------------------- :: Cocoon Win32 Shell Script :: :: $Id: cocoon.bat,v 1.1 2003/02/23 15:15:29 stefano Exp $ :: ----------------------------------------------------------------------------- :: ----- Verify and Set Required Environment Variables ------------------------- if not "%JAVA_HOME%" == "" goto gotJavaHome echo You must set JAVA_HOME to point at your Java Development Kit installation goto cleanup :gotJavaHome :: ----- Set Up The Classpath -------------------------------------------------- set CP=.\tools\lib\forehead-1.0-beta-4.jar :: ----- Check System Properties ----------------------------------------------- set EXEC=start "Cocoon" /D. /MAX if not "%JETTY_PORT%" == "" goto gotPort set JETTY_PORT=8888 :gotPort if not "%JETTY_ADMIN_PORT%" == "" goto gotPort set JETTY_ADMIN_PORT=8889 :gotPort if not "%JETTY_WEBAPP%" == "" goto gotWebapp set JETTY_WEBAPP=build/webapp :gotWebapp if not "%JAVA_DEBUG_PORT%" == "" goto gotWebapp set JAVA_DEBUG_PORT=8000 :gotWebapp :: ----- Check action ---------------------------------------------------------- if ""%1"" == ""cli"" goto doCli if ""%1"" == ""servlet"" goto doServlet if ""%1"" == ""servlet-debug"" goto doDebug echo Usage: cocoon (action) echo actions: echo cli Run Cocoon from command line echo servlet Run Cocoon in a servlet container echo servlet-debug Run Cocoon in a servlet container and turn debug on goto end :: ----- Cli ------------------------------------------------------------------- :doCli %JAVA_HOME%\bin\java.exe -classpath %CP% -Djava.endorsed.dirs=lib\endorsed -Dforehead.conf.file=cocoon.env com.werken.forehead.Forehead %2 %3 %4 %5 %6 %7 %8 %9 goto end :: ----- Servlet --------------------------------------------------------------- :doServlet %EXEC% %JAVA_HOME%\bin\java.exe %JAVA_OPT% -classpath %CP% -Djava.endorsed.dirs=lib\endorsed -Dwebapp=%JETTY_WEBAPP% -Dorg.xml.sax.parser=org.apache.xerces.parsers.SAXParser -Djetty.port=%JETTY_PORT% -Djetty.admin.port=%JETTY_ADMIN_PORT% -Dforehead.conf.file=tools\jetty\conf\jetty.env com.werken.forehead.Forehead tools\jetty\conf\main.xml tools\jetty\conf\admin.xml goto end :: ----- Servlet Debug --------------------------------------------------------- :doDebug %EXEC% %JAVA_HOME%\bin\java.exe %JAVA_OPT% -Xdebug -Xrunjdwp:transport=dt_socket,address=%JAVA_DEBUG_PORT%,server=y,suspend=n -classpath %CP% -Djava.endorsed.dirs=lib\endorsed -Dwebapp=%JETTY_WEBAPP% -Dorg.xml.sax.parser=org.apache.xerces.parsers.SAXParser -Djetty.port=%JETTY_PORT% -Djetty.admin.port=%JETTY_ADMIN_PORT% -Dforehead.conf.file=tools\jetty\conf\jetty.env com.werken.forehead.Forehead tools\jetty\conf\main.xml tools\jetty\conf\admin.xml :: ----- End ----------------------------------------------- :end set CP=