I have a Groovy script which is run like this:
File scriptFile = ...;
ScriptEngine engine = ...;
String script = FileUtils.readFileToString(scriptFile);
Object evalResult = engine.eval(script, bindings);
Unsurprisingly, breakpoint set in the script file doesn't trigger. What can I change to make it work? The script needs to be run in the context of the larger program (no separate launch configuration), and through a ScriptEngine
, and the file is only known at runtime.