         FS.symlink urlToIdPath, urlPath, _
     catch err
         throw err unless err.code is 'EEXIST'
+
+    if Date.now() >= nextLogTime
+        percent = 100 * (i + 1) / totalNumIds
+        remaining = totalNumIds - (i + 1)
+        echo "#{percent.toFixed 2}% processed; #{remaining} files remaining."
+
+echo 'All done!'


config = require '../config'
crypto = require 'crypto'
FS = require 'fs'
Path = require 'path'


    # Massage the data by reading it, modifying it, then writing it back.
    # NOTE: This assumes full knowledge of the starting data.
    data = require idPath   # require() auto-parses JSON!
    ready = (!!data.width and !!data.height) or
        # if we're re-running this after our conversion:
        (!!data.dzi?.width and !!data.dzi?.height)
    data =
        id: id
        url: data.url
        ready: ready
        failed: not ready
        progress: if ready then 1 else 0
        mime: data.mime
        size: data.size
        dzi: data.dzi or {  # braces needed otherwise CS syntax error
