1 Star 0 Fork 0

findroot / shell-test

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
str.sh 297 Bytes
一键复制 编辑 原始数据 按行查看 历史
findroot 提交于 2016-06-23 18:51 . 增加一些测试
#! /bin/bash
#本程序功能为关闭所有打开的终端
ppid=`ps -ef |grep "terminal" |grep -v "grep" |cut -c 10-15`
if [ ! $ppid ];then
echo "进程不存在"
else
for line in `ps -ef |grep $ppid |grep -v "grep" |cut -c 10-15`;do
#echo $line
kill -9 $line
done
fi
Shell
1
https://gitee.com/findroot/test-shell.git
git@gitee.com:findroot/test-shell.git
findroot
test-shell
shell-test
master

搜索帮助