mirror of
https://github.com/drwetter/testssl.sh.git
synced 2025-01-06 08:49:45 +01:00
FIX: show banner when specifying banner option
Addition: show git commit hash and summary instead of 'poor man's ident' :)
This commit is contained in:
parent
c923baaecd
commit
eb3227c837
@ -3063,6 +3063,7 @@ mybanner() {
|
|||||||
hn=$(hostname)
|
hn=$(hostname)
|
||||||
#poor man's ident (nowadays ident not neccessarily installed)
|
#poor man's ident (nowadays ident not neccessarily installed)
|
||||||
idtag=$(grep -a '\$Id' $0 | grep -aw "[E]xp" | sed -e 's/^# //' -e 's/\$ $/\$/')
|
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)"
|
||||||
[ "$COLOR" -ne 0 ] && idtag="\033[1;30m$idtag\033[m\033[1m"
|
[ "$COLOR" -ne 0 ] && idtag="\033[1;30m$idtag\033[m\033[1m"
|
||||||
bb=$(cat <<EOF
|
bb=$(cat <<EOF
|
||||||
|
|
||||||
@ -3509,6 +3510,8 @@ startup() {
|
|||||||
while [[ $# -gt 0 ]]; do
|
while [[ $# -gt 0 ]]; do
|
||||||
case $1 in
|
case $1 in
|
||||||
-b|--banner|-v|--version)
|
-b|--banner|-v|--version)
|
||||||
|
find_openssl_binary
|
||||||
|
mybanner
|
||||||
exit 0;;
|
exit 0;;
|
||||||
--mx)
|
--mx)
|
||||||
do_mx_allentries=true;;
|
do_mx_allentries=true;;
|
||||||
|
Loading…
Reference in New Issue
Block a user