Cygwin Shell下执行java项目

清华大佬耗费三个月吐血整理的几百G的资源,免费分享!....>>>

#please comment the line below when trying to
#set the JAVA_HOME in environment variables
JAVA_HOME=/cygdrive/d/tools/java/1.6.0_45

tail_arg=$1
args=" "
while [ -n "$tail_arg" ]; do
    args="$args $tail_arg"
    if [ "$arg0" = "-cp" -o "$tail_arg" = "-classpath" ]; then
        shift
        tail_arg=$1
        args="$args "`cygpath --path --mix "$tail_arg"`
    fi

    shift
    tail_arg=$1
done


$JAVA_HOME/bin/java $args