I can't seem to import the commands from one Beanshell script to another. I keep getting "Error in script callingScript Command not found: helloWorld()"
Here's my calling script:
// c:/myProjectDir/bsh/callingScript.bsh
...
addClassPath("/bsh"); // My default directory is myProjectDir
importCommands("utils");
helloWorld();
And my called script:
// c:/myProjectDir/bsh/utils/HelloWorld.bsh
helloWorld() {
System.out.println("Hello World!");
}
When I print out the classpath right before running importCommands I get:
Classpath:
... (random jars)
file:/C:/myProjectDir/bsh/
I've seen beanshell documentation and other resources that all show something like this and seem to work. I just can't figure out what I'm doing differently (read: wrong) which is preventing the import from happening.
Thanks!