root检测

This commit is contained in:
gfdgd xi 2023-03-04 16:04:09 +08:00
parent 622bff338c
commit 8ce5226c0c

View File

@ -1,5 +1,5 @@
#!/bin/bash
if [[ `whoami` != `root` ]]; then
if [[ `whoami` != root ]]; then
echo 请以 root 权限运行
echo 按任意键退出
read