Russel Winder | 8 May 19:30

Re: [groovy-dev] startGroovy.bat

On Thu, 2008-05-08 at 18:14 +0200, Jochen Theodorou wrote:
> Russel Winder schrieb:
> > Now whereas the Posix shell script startGroovy declares a function so
> > that variables can be changed after reading the script before calling
> > the function -- in particular STARTER_CLASSPATH -- the Windwoes batch
> > file does a simple execute.
> > 
> > In both cases the script sets STARTER_CLASSPATH assuming there is no
> > prior definition.  For the Posix script there is a way round this, for
> > the Windoze batch files there probably isn't -- or is there, remember I
> > have only just taught myself batch file scripting in the last 10mins.
> > 
> > I think the definitions of STARTER_CLASSPATH should allow for an
> > existing definition in both Posix and Windos scripts.
> > 
> > Unless I am missing something.
> 
> STARTER_CLASSPATH is thought as internal variable, not as something from 
> the outside.

Possibly, but the way it works at the moment severely restricts the
reusability of the script.  I think that startGroovy and startGroovy.bat
can be tinkered with slightly to make them far more efficacious for
launch scripts other than groovy and groovyc.  There are built in
assumptions that the scripts will all be in $GROOVY_HOME and that
$GROOVY_HOME/lib/groovy*.jar is the groovy jar.

I don't think it would take much rearrangement to make them far more
flexible and therefore usable by groovy-based systems that are not
colocated in  $GROOVY_HOME.

--

-- 
Russel.
====================================================
Dr Russel Winder                 Partner

Concertant LLP                   t: +44 20 7585 2200, +44 20 7193 9203
41 Buckmaster Road,              f: +44 8700 516 084
London SW11 1EN, UK.             m: +44 7770 465 077

Gmane