Search
j0ke.net Open Build Service
>
Projects
>
Java
>
jpackage-utils
> jarwrapper
Sign Up
|
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File jarwrapper of Package jpackage-utils
#!/bin/bash # /usr/local/java/bin/jarwrapper - the wrapper for binfmt_misc/jar if [ $# -lt 1 ] then echo "Use this program to execute a Java jar file, usage:" echo -e "\t$0 <jar file>.jar" echo echo Press key to exit ... read exit 1; fi if [ ! -x $1 ] then if which kdialog then kdialog --error "$1 does not have execute permission ... please fix" elif which zenity then zenity --error --text="$1 does not have execute permission ... please fix" else echo "$1 does not have execute permission ... please fix" echo read fi exit 1 fi echo "executing:" echo -e "java -jar $1" echo echo if ! java -jar $1 then echo "The execution of $1 failed. The reason is probably that $1 is not an executable jar file. " echo "If you want to unpack $1, call: " echo " jar -xf $1 " fi echo Press key to exit ... read