From 783ab79ab721593b0ac85ab4d8ea9b74fa5fe72e Mon Sep 17 00:00:00 2001 From: Cody Hiar Date: Mon, 13 Feb 2017 09:54:26 -0700 Subject: Adding tpm --- plugins/tpm/scripts/helpers/utility.sh | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 plugins/tpm/scripts/helpers/utility.sh (limited to 'plugins/tpm/scripts/helpers/utility.sh') diff --git a/plugins/tpm/scripts/helpers/utility.sh b/plugins/tpm/scripts/helpers/utility.sh new file mode 100644 index 0000000..de6eb35 --- /dev/null +++ b/plugins/tpm/scripts/helpers/utility.sh @@ -0,0 +1,17 @@ +ensure_tpm_path_exists() { + mkdir -p "$(tpm_path)" +} + +fail_helper() { + local message="$1" + echo "$message" >&2 + FAIL="true" +} + +exit_value_helper() { + if [ "$FAIL" == "true" ]; then + exit 1 + else + exit 0 + fi +} -- cgit v1.2.3