If changes.osm is corrupt, osmium fileinfo will return exit code 1 and the script will terminate, but the diff file will still exist. As a result, the changes will never be applied. This small change simply returns "" if the timestamp can't be read, and the file will be skipped.
If changes.osm is corrupt,
osmium fileinfo
will return exit code 1 and the script will terminate, but the diff file will still exist. As a result, the changes will never be applied. This small change simply returns "" if the timestamp can't be read, and the file will be skipped.