在前面加一段脚本。注意把批处理文件里的注释去掉
@echo off if "%1" == "h" goto begin mshta vbscript:createobject("wscript.shell").run("%~nx0 h",0)(window.close)&&exit :begin ::
@echo off if "%1" == "h" goto begin mshta vbscript:createobject("wscript.shell").run("%~nx0 h",0)(window.close)&&exit :begin :: setlocal & pushd set MAIN_CLASS=com.xxx.JfinalConfig set APP_BASE_PATH=%~dp0 set CP=%APP_BASE_PATH%config;%APP_BASE_PATH%lib\* java -Xverify:none %JAVA_OPTS% -cp %CP% %MAIN_CLASS% endlocal & popd pause
感谢你的分享