
正文
写个shell脚本依次运行每个程序半小时
提示:扫一扫查出行【扫一扫了解最新限行尾号】
复制提示
@echo off
:: 运行时间1800000毫秒
echo wscript.sleep 1800000 >run.vbs
::运行Debug/lab1.exe程序,后面是参数
start Debug/lab1.exe Au -log au.log
start Debug/lab1.exe Bu -log bu.logrun.vbs
::关闭 lab1.exe程序
taskkill /f /im lab1.exe::如果要继续执行其他程序的话就继续写。。
start Debug/lab1.exe A -log a.log
start Debug/lab1.exe B -log b.log
run.vbs
taskkill /f /im lab1.exestart Debug/lab1.exe Afu -log afu.log
start Debug/lab1.exe Bfu -log bfu.log
run.vbs
taskkill /f /im lab1.exestart Debug/lab1.exe Af -log af.log
start Debug/lab1.exe Bf -log bf.log
run.vbs
taskkill /f /im lab1.exestart Debug/lab1.exe Af -ber 1e-4 -log af-ber.log
start Debug/lab1.exe Bf -ber 1e-4 -log bf-ber.log
run.vbs
taskkill /f /im lab1.exe




![【电子书】[职业技术] 《Linux命令行与shell脚本编程大全(第3版)》[Richard Blum][epub+mobi+azw3] 【电子书】[职业技术] 《Linux命令行与shell脚本编程大全(第3版)》[Richard Blum][epub+mobi+azw3]](https://www.04ip.com/template/qe/style/noimg/10.jpg)

