|
20 | 20 | " on crates.io; creating a new release") |
21 | 21 |
|
22 | 22 | tag_name = "v" + crate_version |
23 | | - print(" Tagging commit as " + tag_name) |
24 | 23 | sha = subprocess.run(["git", "rev-parse", "HEAD"], check=True, |
25 | 24 | stdout=subprocess.PIPE).stdout.decode("utf-8").strip() |
| 25 | + print(f" Tagging commit {sha} as {tag_name}") |
26 | 26 |
|
27 | | - subprocess.run([ |
| 27 | + command = [ |
28 | 28 | "gh", "api", "--method", "POST", "-H", "Accept: application/vnd.github+json", |
29 | 29 | "/repos/rust-osdev/bootloader/releases", |
30 | | - "-f", f"tag_name='{tag_name}'", "-f", f"target_commitish='{sha}'", |
31 | | - "-f", f"name='{tag_name}'", |
32 | | - "-f", "body='[Changelog](https://github.com/rust-osdev/bootloader/blob/main/Changelog.md)'", |
| 30 | + "-f", f"tag_name={tag_name}", "-f", f"target_commitish={sha}", |
| 31 | + "-f", f"name={tag_name}", |
| 32 | + "-f", "body=\"[Changelog](https://github.com/rust-osdev/bootloader/blob/main/Changelog.md)\"", |
33 | 33 | "-F", "draft=false", "-F", "prerelease=false", "-F", "generate_release_notes=false", |
34 | | - ]) |
| 34 | + ] |
| 35 | + print(" Running `" + ' '.join(command) + '`') |
| 36 | + subprocess.run(command, check=True) |
35 | 37 |
|
36 | 38 | print(" Done") |
0 commit comments