根据进程名字杀死进程
//第一种方法
ps -ef | grep 进程名字 | grep -v grep | awk '{print $2}' | xargs kill
//第二种方法
killall 进程名字
苹果系统的applescript脚本
set myPath to "项目目录"
set commands to "cd " & quoted form of myPath & "; 项目目录的可执行文件 参数(例如-type=)"
tell application "Terminal"
activate
do script (commands & 参数值(例如"master"))
end tell