-
-
Notifications
You must be signed in to change notification settings - Fork 40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: specify a commit hash when downloading a plan file #1570
Conversation
body=$(gh run list -w "$workflow" -b "$branch" -L 1 --json headSha,databaseId --jq '.[0]') | ||
run_id=$(echo "$body" | jq -r ".databaseId") | ||
head_sha=$(echo "$body" | jq -r ".headSha") | ||
run_id=$(gh run list -c "$pr_head_sha" -w "$workflow" -b "$branch" -L 1 --json databaseId --jq '.[0].databaseId') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
https://cli.github.com/manual/gh_run_list
-c, --commit SHA Filter runs by the SHA of the commit
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If no workflow run is found, the command succeeds but run_id is empty.
|
||
if [ "$head_sha" != "$pr_head_sha" ]; then |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We specify a commit hash when downloading a plan file, so we don't have to check a commit hash anymore.
@@ -1,14 +1,4 @@ | |||
# https://github.com/suzuki-shunsuke/github-comment | |||
post: | |||
invalid-workflow-sha: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This template isn't used anymore.
Unfortunately, |
No description provided.