Skip to content

Instantly share code, notes, and snippets.

Avatar
💭
Always learning!

Ebenézer Rangel Botelho bene20

💭
Always learning!
View GitHub Profile
@ffissore
ffissore / jshell-wrapper
Last active Jan 18, 2022
with jshell-wrapper you get runnable java scripts: it removes the heading shebang, adds an "/exit" for good measure, and passes the result to jshell
View jshell-wrapper
TMP=`mktemp`
tail -n +2 $@ >> $TMP
echo "/exit" >> $TMP
$JAVA_HOME/bin/jshell -q --execution local $TMP
rm $TMP
#put this file in /usr/local/bin/ or somewhere in your $PATH