def zip_artifact(root_dir, name, version, out_dir):
    validate_name(name)
    validate_files_exist(root_dir)
    temp_dir = tempfile.mkdtemp(dir=out_dir)
    artifact_name = "%s-%s." % (name.split('/')[1], version)
    temp_artifact_name = os.path.join(temp_dir, artifact_name)
    prepare_jar(root_dir, temp_artifact_name)
    prepare_pom(root_dir, name, version, temp_dir)
    pwd = os.getcwd()
    zip_path = os.path.join(out_dir, artifact_name + "zip")
    artifact = zipfile.ZipFile(zip_path, 'w')
    os.chdir(temp_dir)
    artifact.write(artifact_name + "pom")
    artifact.write(artifact_name + "jar")
    artifact.close()
    os.chdir(pwd)
    shutil.rmtree(temp_dir)
    print("Zip File created at: %s" % os.path.abspath(zip_path))
    return zip_path


# <----- init Methods ------>
Write to disk as FreeSurfer \*.label file
dataset/ETHPy150Open databricks/spark-package-cmd-tool/python/spark_package/spark_package.py/zip_artifact--crossover with--dataset/ETHPy150Open mne-tools/mne-python/mne/label.py/Label.save