fix #22 write database timestamp to a file

pull/24/head
Etienne Trimaille 2015-12-23 10:49:52 +01:00
rodzic c27a7e066f
commit f164bea4af
2 zmienionych plików z 9 dodań i 0 usunięć

Wyświetl plik

@ -214,6 +214,14 @@ while True:
move(
join(default['IMPORT_QUEUE'], diff),
join(default['IMPORT_DONE'], diff))
# Update the timestamp in the file.
database_timestamp = diff.split('.')[0].split('->-')[1]
file_path = join(default['SETTINGS'], 'timestamp.txt')
timestamp_file = open(file_path, 'w')
timestamp_file.write(database_timestamp)
timestamp_file.close()
print 'Import diff successful : %s' % diff
else:
print >> stderr, 'An error occured in imposm with a diff.'

Wyświetl plik

@ -0,0 +1 @@
UNDEFINED