如何在 shell 脚本中判断软件是否存在
if ! command -v <the_command> &> /dev/null
then
echo "<the_command> could not be found."
exit 1
fi
via. lhunath@stackoverflow
浅影 浅影随想 @lightfantasy · 1.44K subscribers if ! command -v <the_command> &> /dev/null
then
echo "<the_command> could not be found."
exit 1
fi