File tree Expand file tree Collapse file tree 1 file changed +0
-32
lines changed
Expand file tree Collapse file tree 1 file changed +0
-32
lines changed Original file line number Diff line number Diff line change 6767 - name : Deploy to GitHub Pages
6868 id : deployment
6969 uses : actions/deploy-pages@v4
70-
71- update-pr-body :
72- name : Update PR Body
73- needs : deploy
74- runs-on : ubuntu-latest
75- if : github.event.head_commit.message != '' && contains(github.event.head_commit.message, 'Merge pull request')
76- steps :
77- - name : Find Pull Request Number
78- id : find_pr
79- run : |
80- PR_NUMBER=$(echo "${{ github.event.head_commit.message }}" | sed -n 's/.*Merge pull request #\([0-9]\+\).*/\1/p')
81- if [ -z "$PR_NUMBER" ]; then
82- echo "Could not find PR number in commit message."
83- exit 1
84- fi
85- echo "PR_NUMBER=$PR_NUMBER" >> $GITHUB_OUTPUT
86-
87- - name : Update Pull Request Body
88- env :
89- GH_TOKEN : ${{ secrets.GITHUB_TOKEN }}
90- PR_NUMBER : ${{ steps.find_pr.outputs.PR_NUMBER }}
91- PAGE_URL : ${{ needs.deploy.outputs.page_url }}
92- run : |
93- export BODY=$(gh pr view $PR_NUMBER --json body -q .body)
94- export HEADER="🚀 **배포 완료!**\n**배포된 사이트:** [${PAGE_URL}](${PAGE_URL})"
95- gh pr edit $PR_NUMBER --body-file - <<EOF
96- ${HEADER}
97-
98- ---
99-
100- ${BODY}
101- EOF
You can’t perform that action at this time.
0 commit comments