📜  如何获取 pc bash 脚本的名称 - Shell-Bash 代码示例

📅  最后修改于: 2022-03-11 14:50:38.263000             🧑  作者: Mango

代码示例1
computer_name=$(whoami)

if [ $computer_name == "NAME" ]
then
    echo "a is equal to b in NAME pc"
    echo $computer_name
else
    echo "a is not equal to b another pc"
    echo $computer_name
fi