我正在寻找检查gpg-agent是否安装在机器上的最佳方法。我需要从shell脚本中检查。
谢谢。
发布于 2014-09-08 17:47:01
您可能需要修改路径。用RHEL 6和7测试。
if test -x /usr/bin/gpg-agent; then echo installed; else echo not installed; fi或者:
if [ -x /usr/bin/gpg-agent ]; then echo insatlled; else echo not installed; fi进一步阅读:help test。
https://stackoverflow.com/questions/25725431
复制相似问题