📜  bash 如果未设置 - Shell-Bash 代码示例

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

代码示例1
[[ -v foo ]]; echo $?
# 1

foo=bar
[[ -v foo ]]; echo $?
# 0

foo=""
[[ -v foo ]]; echo $?
# 0