summaryrefslogtreecommitdiff
path: root/local/bin/sb-network
diff options
context:
space:
mode:
authorcoasteen <coasteen@proton.me>2026-07-09 10:42:28 +0330
committercoasteen <coasteen@proton.me>2026-07-09 10:42:28 +0330
commit8cbadb61604667b407b53ee1258433994fa4765a (patch)
tree97765fb29418fd6278fcb4cbb9760893afaf7a58 /local/bin/sb-network
Diffstat (limited to 'local/bin/sb-network')
-rwxr-xr-xlocal/bin/sb-network8
1 files changed, 8 insertions, 0 deletions
diff --git a/local/bin/sb-network b/local/bin/sb-network
new file mode 100755
index 0000000..0937126
--- /dev/null
+++ b/local/bin/sb-network
@@ -0,0 +1,8 @@
+#!/bin/sh
+# Show local IP and transfer if connected to the internet. Opens $NETWORKMANAGER on click
+NETWORKMANAGER=connman-gtk
+ifconfig | grep ".*inet.*netmask" | tail -n 1 | sed 's/inet //g' | sed 's/ netmask.*//g' | sed 's/ //g' | sed 's/ //g'
+
+case $BLOCK_BUTTON in
+ 1) $NETWORKMANAGER ;;
+esac