diff options
Diffstat (limited to '.config/waybar/modules/vpn.sh')
| -rwxr-xr-x | .config/waybar/modules/vpn.sh | 24 |
1 files changed, 0 insertions, 24 deletions
diff --git a/.config/waybar/modules/vpn.sh b/.config/waybar/modules/vpn.sh deleted file mode 100755 index c4d50fa..0000000 --- a/.config/waybar/modules/vpn.sh +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/sh - -set -e -[ -n "$DEBUG" ] && set -x - -case "$1" in -toggle) exit 1 ;; -esac - -extern_ip=$(curl -SsfL http://api.ipify.org/?format=text) - -vpn_is_up() { - case "$extern_ip" in - 138.201.245.159) return 0 ;; # hetzner node - esac - return 1 -} - -if vpn_is_up; then - printf '{"text": "", "tooltip": "external ip is %s"}\n' "$extern_ip" -else - # printf '{"text": "", "tooltip": "disconnected"}\n' - printf '{}\n' -fi |