projects
/
project
/
luci.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
(from parent 1:
e846f38
)
Merge pull request #879 from bittorf/master
author
Hannu Nyman
<hannu.nyman@iki.fi>
Wed, 14 Dec 2016 08:08:19 +0000
(10:08 +0200)
committer
GitHub
<noreply@github.com>
Wed, 14 Dec 2016 08:08:19 +0000
(10:08 +0200)
freifunk-common: neigh.sh: work also with unprettyfied JSON output
contrib/package/freifunk-common/files/usr/bin/neigh.sh
patch
|
blob
|
history
diff --git
a/contrib/package/freifunk-common/files/usr/bin/neigh.sh
b/contrib/package/freifunk-common/files/usr/bin/neigh.sh
index
59ea8f9
..
468ed7a
100755
(executable)
--- a/
contrib/package/freifunk-common/files/usr/bin/neigh.sh
+++ b/
contrib/package/freifunk-common/files/usr/bin/neigh.sh
@@
-66,7
+66,7
@@
VARS="$VARS neighborLinkQuality:NLQ linkCost:Cost remoteHostname:Host"
for HOST in '127.0.0.1' '::1';do
json_init
- json_load "$( echo /links | nc $HOST 9090 |
grep ^'{' )"
# remove header/non-json
+ json_load "$( echo /links | nc $HOST 9090 |
sed -n '/^[}{ ]/p' )"
# remove header/non-json
if json_is_a links array;then
json_select links