Skip to content

Commit

Permalink
Fix PR install note syntax
Browse files Browse the repository at this point in the history
  • Loading branch information
EwoutH authored Oct 3, 2024
1 parent 02c8210 commit 827aa6a
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions .github/workflows/pr_branch_message.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
name: PR install note

name: PR Install Note
on:
pull_request:
types: [opened]
types: [opened, reopened, ready_for_review]

jobs:
add-install-note:
Expand All @@ -19,12 +18,14 @@ jobs:
FORK_NAME=$(gh pr view $PR_NUMBER --json headRepositoryOwner -q .headRepositoryOwner.login)
PR_BRANCH=$(gh pr view $PR_NUMBER --json headRefName -q .headRefName)
REPO_OWNER=${FORK_NAME:-projectmesa}
INSTALL_NOTE="
INSTALL_NOTE=$(cat << EOF
You can install this PR branch with:
\`\`\`
pip install -U -e git+https://github.com/${REPO_OWNER}/mesa@${PR_BRANCH}#egg=mesa
\`\`\`"
You can install this PR branch with:
\`\`\`
pip install -U -e git+https://github.com/${REPO_OWNER}/mesa@${PR_BRANCH}#egg=mesa
\`\`\`
EOF
)
NEW_PR_BODY="${PR_BODY}${INSTALL_NOTE}"
gh pr edit $PR_NUMBER --body "$NEW_PR_BODY"

0 comments on commit 827aa6a

Please sign in to comment.