更新 .gitea/workflows/demo.yaml
Gitea Actions Demo / Explore-Gitea-Actions (pull_request) Successful in 46s Details

测试合并请求
This commit is contained in:
xiehaijun 2025-07-26 16:55:37 +00:00
parent 866a7c099c
commit 929b7939a1
1 changed files with 5 additions and 0 deletions

View File

@ -53,6 +53,11 @@ jobs:
if: github.event_name == 'pull_request'
run: |
echo "是否是合并关闭的 $PR_STATUS_FLAG"
if [[ "$PR_STATUS_FLAG" = true ]] ; then
echo "合并完成"
else
echo "取消合并"
fi
pr_num=${{ github.event.pull_request.number }}
git fetch origin refs/pull/${pr_num}/head:refs/remotes/origin/pull/${pr_num}/head
commit_title=$(git log -1 --pretty=format:"%s" origin/pull/${pr_num}/head)