function dirsToCreate(files) {
  return uniqueDirs(files).sort(byShortPath);
}
Generate a list of directories to create given a list of file paths.
@param {Array<string>} files List of file paths.
@return {Array<string>} List of directory paths ordered by path length.