脚本之家,脚本语言编程技术及教程分享平台!
分类导航

Python|VBS|Ruby|Lua|perl|VBA|Golang|PowerShell|Erlang|autoit|Dos|bat|shell|

服务器之家 - 脚本之家 - shell - shell脚本运行5秒后自动退出的代码

shell脚本运行5秒后自动退出的代码

2022-12-13 12:13shell编程教程 shell

shell脚本运行5秒自动退出的代码,供大家学习参考

复制代码 代码如下:


#!/bin/bash
#name show_status.sh
#echo $$ > /var/run/show_status.log
#sleep 5 && kill `cat /var/run/show_status.log` &
#start code
echo "hello world"
#end code

延伸 · 阅读

精彩推荐