Upgrade the release tooling to ReleaseKit v0.3.0
This commit is contained in:
@@ -216,6 +216,11 @@ def prepare_repository(repository, remote, environment, module_bytes, version):
|
||||
|
||||
|
||||
def verify_publication(repository, remote, temporary_root, environment, module_bytes, selected_go):
|
||||
selected_releasekit = run(
|
||||
["go", "list", "-mod=readonly", "-m", "-f", "{{.Version}}", RELEASEKIT_MODULE],
|
||||
cwd=repository,
|
||||
environment=environment,
|
||||
).strip()
|
||||
publication = repository / "scripts/release.sh"
|
||||
run(
|
||||
[str(publication), RELEASE_VERSION],
|
||||
@@ -249,9 +254,11 @@ def verify_publication(repository, remote, temporary_root, environment, module_b
|
||||
first_line = build_info.splitlines()[0]
|
||||
if selected_go not in first_line:
|
||||
raise RuntimeError(f"tool was built with {first_line!r}, expected {selected_go}")
|
||||
expected_module = f"\tmod\t{RELEASEKIT_MODULE}\tv0.2.0\t"
|
||||
expected_module = f"\tmod\t{RELEASEKIT_MODULE}\t{selected_releasekit}\t"
|
||||
if expected_module not in build_info:
|
||||
raise RuntimeError("bootstrap executable does not record ReleaseKit v0.2.0")
|
||||
raise RuntimeError(
|
||||
f"bootstrap executable does not record selected ReleaseKit {selected_releasekit}"
|
||||
)
|
||||
|
||||
candidate = repo_git(repository, environment, "rev-parse", "HEAD").strip()
|
||||
if repo_git(repository, environment, "rev-parse", "main").strip() != candidate:
|
||||
|
||||
Reference in New Issue
Block a user