Java beanshell

From wikinotes
Revision as of 16:44, 19 April 2019 by Will (talk | contribs) (→‎Usage)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

beanshell is a commandline program that executes java code within an interpreted environment. It's pretty useful for testing things out.

Documentation

http://beanshell.org/manual/contents.html

Install

sudo pacman -S beanshell

Usage

add jar to environment

export CLASSPATH=$CLASSPATH:/usr/share/java/bsh.jar
# GUI (have not used)
java  bsh.Console

# CLI
java  bsh.Interpreter
java  bsh.Interpreter   file.java   # run file within interpreted environment

NOTE:

I wrote an alias for this 'bsh'