summaryrefslogtreecommitdiff
path: root/.i3blocks/blocklets/openvpn
diff options
context:
space:
mode:
authorluxagraf <sng@luxagraf.net>2020-02-16 13:23:56 -0500
committerluxagraf <sng@luxagraf.net>2020-02-16 13:23:56 -0500
commitcd507c92f617d4a8a3f7bb0b43e425491ef7184d (patch)
tree42144ef0f35b91e7955f570c5ecc4bcec3c4d780 /.i3blocks/blocklets/openvpn
initial commit of dotfiles
Diffstat (limited to '.i3blocks/blocklets/openvpn')
-rwxr-xr-x.i3blocks/blocklets/openvpn3
1 files changed, 3 insertions, 0 deletions
diff --git a/.i3blocks/blocklets/openvpn b/.i3blocks/blocklets/openvpn
new file mode 100755
index 0000000..8139436
--- /dev/null
+++ b/.i3blocks/blocklets/openvpn
@@ -0,0 +1,3 @@
+#!/bin/bash
+result=$(nmcli -t -f type,state,connection d | egrep "^(tun|tap):connected" | awk -F':' '{ print $3 }')
+[[ -z $result ]] && echo '' || echo ""