From 764f20dbcf9e4d667c021fa46c2370e05a565ac9 Mon Sep 17 00:00:00 2001 From: Peter Mosmans Date: Sat, 30 May 2015 11:13:57 +0200 Subject: [PATCH] FIX: Show version when specified on command line ADDITION: Show git commit information, to support troubleshooting. --- testssl.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/testssl.sh b/testssl.sh index 57d2d45..3d4fe7c 100755 --- a/testssl.sh +++ b/testssl.sh @@ -3076,6 +3076,7 @@ mybanner() { hn=$(hostname) #poor man's ident (nowadays ident not neccessarily installed) idtag=$(grep -a '\$Id' $0 | grep -aw "[E]xp" | sed -e 's/^# //' -e 's/\$ $/\$/') + which git &>/dev/null && idtag="$(git log --format='%h %s (%ci)' -1 2>/dev/null)" [ "$COLOR" -ne 0 ] && idtag="\033[1;30m$idtag\033[m\033[1m" bb=$(cat <