'Determine if repository\'s tool config file on disk can be used.  This method
is restricted to tool config files since, with the exception of tool config
files, multiple files with the same name will likely be in various directories
in the repository and we\'re comparing file names only (not relative paths).'

def can_use_tool_config_disk_file(self, repository, repo, file_path, changeset_revision):

    if ((not file_path) or (not os.path.exists(file_path))):
        return False
    if (changeset_revision == repository.tip(self.app)):
        return True
    file_name = basic_util.strip_path(file_path)
    latest_version_of_file = self.get_latest_tool_config_revision_from_repository_manifest(repo, file_name, changeset_revision)
    can_use_disk_file = filecmp.cmp(file_path, latest_version_of_file)
    try:
        os.unlink(latest_version_of_file)
    except:
        pass
    return can_use_disk_file
