vpnmenu (376B) - raw


      1 #!/bin/sh
      2 
      3 region="$(piactl get regions | dmenu -p "Select Region: ")"
      4 update=$(kill -36 $(pidof dwmblocks))
      5 
      6 [ "$region" == "" ] && notify-send -a " VPN" "Operation aborted"
      7 [ "$region" 	!= "" ] && piactl set region "$region" && \
      8 	 $update && notify-send -a " VPN" "Changed region to $region" && \
      9 	sleep 3 && $update
     10 # Comment next line if not using the vpn dwmblock