summaryrefslogtreecommitdiff
path: root/.config/wmii-hg/rbar_wifi
diff options
context:
space:
mode:
authorLuke Shumaker <lukeshu@sbcglobal.net>2016-12-07 19:57:05 -0500
committerLuke Shumaker <lukeshu@lukeshu.com>2017-02-11 18:59:43 -0500
commit07ec79433657e754965dd2eb7a324512d46a72ee (patch)
treebd95000d24a373a9c1b9a6a7186d2a7b98cd3d14 /.config/wmii-hg/rbar_wifi
parentddb7692a2f93dca1ebf39a8ea7a710363aea516a (diff)
rbar: be more compact
Diffstat (limited to '.config/wmii-hg/rbar_wifi')
-rwxr-xr-x.config/wmii-hg/rbar_wifi11
1 files changed, 1 insertions, 10 deletions
diff --git a/.config/wmii-hg/rbar_wifi b/.config/wmii-hg/rbar_wifi
index d201152..e740777 100755
--- a/.config/wmii-hg/rbar_wifi
+++ b/.config/wmii-hg/rbar_wifi
@@ -1,14 +1,5 @@
#!/usr/bin/env bash
-iwinfo() {
- local interface=$1
- iwconfig "$interface" |
- sed -r 's/ {2,}/\n/g' |
- sed -e '/^\s*$/d' -e 's/:\s*/=/' \
- -e '1s/^/Interface=/' \
- -e '2s/^/MAC Protocol=/'
-}
-
update() {
local iface=wlp2s0
@@ -18,7 +9,7 @@ update() {
while true; do
IFS=$'\n'
lines=($(
- iwinfo "$iface" | sed -rn 's@^(ESSID|Link Quality)=@@p'
+ iwdata "$iface" | sed -rn 's@^(ESSID|Link Quality)=@@p'
ifdata -pa "$iface"
))
IFS='|'