1
0
mirror of https://github.com/dcarrillo/dotfiles.git synced 2025-03-15 03:05:24 +00:00

21 lines
428 B
Bash
Executable File

#!/usr/bin/env bash
openvpn_icon="%{T2}%{T-}"
globalprotect_icon="%{T2}%{T-}"
wireguard_icon="%{T2}󰒃%{T-}"
output=""
if pgrep openvpn >/dev/null; then
output=${openvpn_icon}
fi
if pgrep gpclient >/dev/null; then
output="${output} ${globalprotect_icon}"
fi
if ip route list | grep 'dev wg0 proto kernel scope link' >/dev/null; then
output="${output} ${wireguard_icon}"
fi
echo "%{F#43a047}$output%{F-}"