write nodes.json directly without creating nodes.json.new first

alfred-data
Nils Schneider 2013-11-23 22:09:27 +01:00
parent d38670a5a1
commit 573d32c29d
2 changed files with 1 additions and 4 deletions

View File

@ -64,6 +64,6 @@ rrd.update_images()
m = D3MapBuilder(db) m = D3MapBuilder(db)
nodes_json = open(options['destination_directory'] + '/nodes.json.new','w') nodes_json = open(options['destination_directory'] + '/nodes.json','w')
nodes_json.write(m.build()) nodes_json.write(m.build())
nodes_json.close() nodes_json.close()

View File

@ -11,6 +11,3 @@ DEST=$1
"$(dirname "$0")"/ffhlwiki.py http://freifunk.metameute.de/wiki/Moelln:Knoten > "$(dirname "$0")"/aliases_moelln.json "$(dirname "$0")"/ffhlwiki.py http://freifunk.metameute.de/wiki/Moelln:Knoten > "$(dirname "$0")"/aliases_moelln.json
"$(dirname "$0")"/bat2nodes.py -a "$(dirname "$0")"/aliases.json -a aliases_hl.json -a aliases_moelln.json -d $DEST $GWS - "$(dirname "$0")"/bat2nodes.py -a "$(dirname "$0")"/aliases.json -a aliases_hl.json -a aliases_moelln.json -d $DEST $GWS -
mv $DEST/nodes.json.new $DEST/nodes.json