summaryrefslogtreecommitdiff
path: root/.config/polybar/protonvpn_status.sh
blob: 1e2b90a401d781f7335f785a643fc2eca8901f5e (plain)
1
2
3
4
5
6
7
8
9
10
11
#!/bin/bash
set -euo pipefail
IFS=$'\n\t'

PROTONVPN_STATUS=$(curl -s https://am.i.mullvad.net/country)

if echo $PROTONVPN_STATUS | grep -q 'Uruguay'; then
  echo "%{u#f90000}VPN %{T5}🚫%{T-}"
 else
  echo "%{u#75d85a}VPN %{T5}✅%{T-}"
fi