Can Jshell be added? It's a standard feature of the JDK. It's executed like this:
$JAVA_HOME/bin/jshell <file>
. It might be necessary to
automatically add \n/exit
at the end of the script since there is no way to automatically shut it down with the command line...