Skip to content

Commit

Permalink
.github/workflows/codeql.yml: Use cargo-make 0.37.9
Browse files Browse the repository at this point in the history
Matches the version specified in rust-toolchain.toml since this is
now checked during build. A file sync will follow in the future to
update the version as it changes in Mu DevOps Version.njk file.

Signed-off-by: Michael Kubacki <[email protected]>
  • Loading branch information
makubacki committed Feb 24, 2024
1 parent e5ba7e0 commit 884ceb1
Showing 1 changed file with 12 additions and 6 deletions.
18 changes: 12 additions & 6 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -159,17 +159,23 @@ jobs:
import requests
GITHUB_REPO = "sagiegurari/cargo-make"
API_URL = f"https://api.github.com/repos/{GITHUB_REPO}/releases/latest"
api_url = f"https://api.github.com/repos/{GITHUB_REPO}/releases/tags/0.37.9"
# Default value in case getting latest fails, cache will fall
# back on this version.
latest_cargo_make_version = "0.36.13"
response = requests.get(API_URL)
response = requests.get(api_url)
if response.status_code == 200:
build_release_id = response.json()["id"]
else:
print("::error title=GitHub Release Error!::Failed to get cargo-make release ID!")
sys.exit(1)
api_url = f"https://api.github.com/repos/{GITHUB_REPO}/releases/{build_release_id}"
response = requests.get(api_url)
if response.status_code == 200:
latest_cargo_make_version = response.json()["tag_name"]
else:
print("::error title=GitHub Release Error!::Failed to get latest cargo-make version!")
print("::error title=GitHub Release Error!::Failed to get cargo-make!")
sys.exit(1)
cache_key = f'cargo-make-{latest_cargo_make_version}'
Expand Down

0 comments on commit 884ceb1

Please sign in to comment.