Closed rubo77 closed 9 years ago
This patch will simply add a file blacklist in the main folder that contains the wrong and correct longitude and latitude values each in one line with a slash between. Then this file wil be used to replace the wrong coordinates with the correct:
create a file blacklist
like
54.357991097/54.32738396458
10.134319067/10.13090193271
and add this line in mkmap.sh
:
cat blacklist|while read geo ; do if [ "$geo" != "" ]; then sed -i s/$geo/ json/nodes.json; fi; done
Where json/nodes.json
is the generated nodes.json file.
Here is our git patch:
blacklist | 3 +++
mkmap.sh | 5 +++++
2 files changed, 8 insertions(+)
create mode 100644 blacklist
diff --git a/blacklist b/blacklist
new file mode 100644
index 0000000..d03fe7e
--- /dev/null
+++ b/blacklist
@@ -0,0 +1,3 @@
+54.357991097/54.32738396458
+10.134319067/10.13090193271
+
diff --git a/mkmap.sh b/mkmap.sh
index 97fe040..f120107 100755
--- a/mkmap.sh
+++ b/mkmap.sh
@@ -17,3 +17,8 @@ jq -c 'with_entries(select(.value.vpn == true) | {key, value: {"vpn": .value.vpn
./bat2nodes.py --alfred json/alfred.158.json --aliases json/aliases.json --mesh json/batman.json -d $DEST
+# the file blacklist contains long and latitude values, that should be replaced in the form
+# 53.123456/53.456789
+# 10.123456/10.456789
+cat blacklist|while read geo ; do if [ "$geo" != "" ]; then sed -i s/$geo/ json/nodes.json; fi; done
+
--
2.1.4
Es gibt gar keine mkmap.sh mehr im repository.
mkmap.sh/bat2nodes sind Teil des deprecated branches, der nicht mehr maintained wird.
Ich hab das hier einfach mal gepostet falls das jemand braucht.
Ich weis: es ist ein Hack und es wäre sauberer, wenn man die Knotenbetreiber erreichte um die Koordinaten zu korrigieren, aber manchmal ist dies einfach nicht mehr möglich, und es bliebe als alternative nur noch, die Keys aller angrenzenden uplinks zu sperren (meisst unakzeptabel)
Dieses alte Backend wird mit der übernächsten Gluon Version nicht mehr Funktionieren, man sollte also auf den meshviewer für den Graphen und die Liste umsteigen und die http://freifunk-karte.de für die Map (http://www.freifunk-emskirchen.de/de-map/)
I can think of three reasons, why you want to hide the coordinates from the map:
We would need a functionality to blacklist certain nodes on the map for cases
solutions for those:
so the blacklist would have to have two options:
(This was preciedingly posted at https://github.com/ffnord/ffmap-d3/issues/112)