From: nr nr <news0reader@ho...> - 2003-04-09 03:28:01
I haven't run Jython on u*ix so I'm not the best qualified to answer this.
Still, you may find the follwoing useful.
The java interpreter looks for classes it needs to load in an environment
variable (a shell variable in u*ix) called CLASSPATH. If you want to use
this feature I believe u*ix systems allow you to set and 'export' such vars
as part of, say, a login script. Thus, if during development you *always*
wanted certain java resources to be available, setting CLASSPATH is a good
You may also tell java where to look for classes, for a specific invocation,
via its -classpath (abbreviated -cp) switch. Thus, if invoking the java
interpreter from the commandline, the syntax would be:
java -cp <list of paths to search> <class-to-execute>
java then provides resources specified in -cp's args to <class-to-execute>.
Now why all this talk of java? It's because jython is just a java program,
and is invoked just like any other java program. The "jython" command that
you use to invoke jython is likely just a shell script that wraps a
commandline such as the above.
Thus if you want specific jars, etc to be available to jython, and don't
want to set a CLASSPATH, you may type them in interactively or, edit your
jython wrapper script to include them.
The new MSN 8: advanced junk mail protection and 2 months FREE*