code: function removeExtension(file) {
    let parts = path.parse(file);
    delete parts.ext;
    delete parts.base;
    return path.format(parts);
  }
docs: given a file path (including directory), this function will remove the extension and then put all the other pieces back together into a normalized path string