aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastiano Tronto <sebastiano.tronto@gmail.com>2022-05-10 15:09:40 +0200
committerSebastiano Tronto <sebastiano.tronto@gmail.com>2022-05-10 15:09:40 +0200
commit675d70e616cb764c685070427a914e4b99f3cee7 (patch)
tree161340d4191046ae881419034834f6750a9150e6
parent133dd8180878a68845695d48af50d7f20d1bc8db (diff)
downloadscripts-675d70e616cb764c685070427a914e4b99f3cee7.tar.gz
scripts-675d70e616cb764c685070427a914e4b99f3cee7.zip
Fixed Network status (what kind of cli program add random white spaces at the end of a line? why? WHY?!?!)
-rwxr-xr-xstatus5
1 files changed, 4 insertions, 1 deletions
diff --git a/status b/status
index 0f45a96..7a2825f 100755
--- a/status
+++ b/status
@@ -21,7 +21,10 @@ else
21fi 21fi
22 22
23#network=$(nmcli device status | head -n 2 | tail -n 1 | awk '{print "Network: " $4}') 23#network=$(nmcli device status | head -n 2 | tail -n 1 | awk '{print "Network: " $4}')
24network="Network: $(nmcli device status | head -n 2 | tail -n 1 | sed 's/.* //')" 24# NetworkManager has a dreadful command line interface
25# It makes cry every time
26# pls help
27network="Network: $(nmcli device status | head -n 2 | tail -n 1 | sed 's/ *$//' | sed 's/.* //')"
25 28
26events=$(sdep-list past | wc -l) 29events=$(sdep-list past | wc -l)
27 30

Generated with cgit - Back to sebastiano.tronto.net