   fix_cache = (cache,ix) ->
     if ix >= cache.files.length
       # done!
-      console.log 'write cache.js'
+      console.log 'write cache.json'
       fs.writeFileSync cachefn,JSON.stringify cache
     else
       file = cache.files[ix]

  # un-needed files in cache?
  for oldfile in oldfiles when oldfile.path? and not oldfile.needed 
    cache.files.push oldfile

# get local cache path for an URL - like java cacheing,
# maps domain name elements and path elements to folders

  hs = ["cache"].concat hs,ps
  # make safe filenames
  hs = for h in hs
    get_filename_for_component h
  path = hs.join '/'
  return path

