Skip to content
Advertisement

Tag: shell

Return Java system exit value to bash script

I am trying to get the return value from a java program ( System.exit(1);) into a shell script, but it seems like its returning the jvm exit code, which is always 0, if it doesnt crash. For testing purposes, this is the very first line in my main(). Anyone know how to do this? My bash code: Thanks Answer If

Advertisement