@ECHO OFF
:: this is the script mywork.bat for Windows.
:: The idea is to use this script to start myforth projects
:: This script should be moved to your home bin directory
:: where your personal path statement will pick it up.
:: There is no defined home directory in windows - so it 
:: could be in the root path of your - C:\myforth\bin
:: this will allow you to be anywhere in the subversion
:: working directory tree and run one of the project scripts
:: inorder to perform a build or connection. You should edit this
:: file to match your scope of tasks and projects.
:: You will need to add your bin path to the windows path statement.
::
:: This script is invoked with the myforth script you wish to run
:: and any other options you need to pass along.
:: You must edit this script to enter the location of your working
:: svn repository - it will be the path you gave to the "svn co" command.
:: define the location of the working directory and export for later use.

SET SVNROOT=C:\myforth\co

:: now we start through the possible scripts

if "%1" == "c" (
   CALL %SVNROOT%\trunk\source\utils\c.bat
   GOTO:EOF
)

if "%1" == "d" (
   CALL %SVNROOT%\trunk\source\utils\d.bat
   GOTO:EOF
)

if "%1" == "run" ( 
   CALL %SVNROOT%\trunk\source\utils\run.bat %2
   GOTO:EOF
)

if "%1" == "sees" (
   CALL %SVNROOT%\trunk\source\utils\sees.bat %2 %3
   GOTO:EOF
)

if "%1" == "gforth" (
   CALL C:\PROGRA~1\gforth\gforth.exe %2 %3 %4
   GOTO:EOF
)

if "%1" == "examples" (
   CD %SVNROOT%\trunk\projects\examples
   GOTO:EOF
)

:: When called we should have a passed script to run - however
:: if no scipt passed or not one of the above - echo the list.

:Syntax
ECHO.
ECHO The syntax of this bat file - mywork.bat - expects at least one
ECHO passed parameter - the possible options are:
ECHO    PROJECTS: examples
ECHO    BAT FILES: c d run sees
ECHO    PROGRAMS: gforth
ECHO.  

:END