mirror of
https://github.com/dcarrillo/dotfiles.git
synced 2025-03-14 17:45:24 +00:00
[polybar] Add wireguard to check_vpn
This commit is contained in:
parent
40310a71e5
commit
cb37621f00
@ -2,6 +2,7 @@
|
||||
|
||||
openvpn_icon="%{T2}%{T-}"
|
||||
globalprotect_icon="%{T2}%{T-}"
|
||||
wireguard_icon="%{T2}%{T-}"
|
||||
|
||||
output=""
|
||||
if pgrep openvpn >/dev/null; then
|
||||
@ -12,4 +13,8 @@ if pgrep gpclient >/dev/null; then
|
||||
output="${output} ${globalprotect_icon}"
|
||||
fi
|
||||
|
||||
echo "%{F#e7c111}$output%{F-}"
|
||||
if ip route list | grep 'dev wg0 proto kernel scope link' >/dev/null; then
|
||||
output="${output} ${wireguard_icon}"
|
||||
fi
|
||||
|
||||
echo "%{F#43a047}$output%{F-}"
|
||||
|
Loading…
x
Reference in New Issue
Block a user