所带参数也是 Linux上某个文件目录中的一个 exe文件
Runtime rt = Runtime.getRuntime();
String[] cmd = {"/bin/sh","-c","source /home/hcc/mxDraw/dwg/test.sh test.exe"}
Process proc = rt.exec(cmd);
shell 脚本
# Date:2021年10月14日 10:37:19
# Version: 1.1
cd /home/hcc/mxDraw/dwg;
/home/hcc/mxDraw/MxDrawServer $1
注: source命令又称为点命令,作用:在当前shell环境下读取并执行脚本中的命令,通常用于重新执行刚修改过的初始化文件,使之立即生效,而不必注销并登录。