def get_license_replacement(license_id, just_name=False):
    if license_id != len(licenses):
        license_name, license_url = licenses[license_id - 1]
        if just_name:
            return "$$license$$", license_name
        return ("$$license$$",
                "licenses := Seq(\"%s\" -> url(\"%s\"))\n" % (license_name, license_url))
    else:
        if just_name:
            return "$$license$$", "Please specify a license"
        return "$$license$$", "// format: licenses := Seq($LICENSE_NAME -> $LICENSE_URL)"
dataset/ETHPy150Open databricks/spark-package-cmd-tool/python/spark_package/spark_package.py/get_license_replacement/original