From 7e95c3b667a1b353f8275db886203f272bfcce34 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jes=C3=BAs?= Date: Wed, 10 Feb 2021 13:52:52 -0500 Subject: first commit --- build.sh | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 build.sh (limited to 'build.sh') diff --git a/build.sh b/build.sh new file mode 100644 index 0000000..c398823 --- /dev/null +++ b/build.sh @@ -0,0 +1,24 @@ +#!/bin/bash + +if [[ -n "$(ls -a ./hyperterm/)" && -f ./.bash_profile ]]; +then + cd ./hyperterm/ || exit + + var1=$(find ../ -name ".bash*" -type f -exec sha512sum {} \;) + var2=$(find . -type f -name "*.sh" ! -iname "_custom.sh" -exec sha512sum {} \;) + + alist="echo $var1 $var2" + $alist > tmp.txt + + output="fmt -w 160 tmp.txt" + + $output > hyperterm.sha512 + + rm -rf tmp.txt + + sha512sum -c hyperterm.sha512 + + printf '\e[1;36m%s\e[m\n' "success hyperterm.sha512" +else + printf '\e[1;31m%s\e[m\n' "Error! files not found for verification" +fi -- cgit v1.2.3