标签:用户id bin please col lse root div use bsp
环境变量UID中保存的是用户ID。 root用户的UID是0。
#! /bin/bash if [ $UID -ne 0 ]; then echo Non root user. Please run as root. else echo Root user fi
标签:用户id bin please col lse root div use bsp
原文地址:https://www.cnblogs.com/shix0909/p/13522918.html