brush up a tad
This commit is contained in:
parent
5b0230806b
commit
54fa7b7eae
@ -10,11 +10,9 @@ http://ifconfig.io/
|
|||||||
PUBLIC_IP_FETCH_URL="https://icanhazip.com"
|
PUBLIC_IP_FETCH_URL="https://icanhazip.com"
|
||||||
PUBLIC_IP6_FETCH_URL="$PUBLIC_IP_FETCH_URL"
|
PUBLIC_IP6_FETCH_URL="$PUBLIC_IP_FETCH_URL"
|
||||||
|
|
||||||
printf "%s / %s\n" \
|
printf '%s\ts\n' \
|
||||||
"$(curl -4 --connect-timeout 5 --silent "$PUBLIC_IP_FETCH_URL")" \
|
"$(curl -4 --connect-timeout 5 --silent "$PUBLIC_IP_FETCH_URL")" \
|
||||||
"$(curl -6 --connect-timeout 5 --silent "$PUBLIC_IP6_FETCH_URL")" \
|
"$(curl -6 --connect-timeout 5 --silent "$PUBLIC_IP6_FETCH_URL")" \
|
||||||
| sed -e 's/ \/ $//' \
|
| sed -e 's/ \/ $//' \
|
||||||
-e 's/^ \/ //' \
|
-e 's/^ \/ //' \
|
||||||
-e 's/^$/[error fetching address]/'
|
-e 's/^$/[error fetching address]/'
|
||||||
|
|
||||||
exit 0
|
|
||||||
|
Loading…
Reference in New Issue
Block a user