added exit for missing programs

This commit is contained in:
2022-12-30 17:44:19 -05:00
parent e011138c0d
commit 8ce5763430

View File

@@ -368,10 +368,13 @@ if __name__ == "__main__":
# check if required programs are installed
if not shutil.which(bitwarden_cli_executable):
print("Bitwarden CLI ({}) cannot be found. Please make sure it is installed and executable.".format(bitwarden_cli_executable))
sys.exit(1)
elif not shutil.which(gpg_executable):
print("GPG ({}) cannot be found. Please make sure it is installed and executable.".format(gpg_executable))
sys.exit(1)
elif not shutil.which(secure_delete_executable):
print("SRM/sdelete.exe ({}) cannot be found. Please make sure it is installed and executable.".format(secure_delete_executable))
sys.exit(1)
client = client.ProxyKmipClient(config_file=pykmip_client_config_file)
client.open()