blog/.gitea/workflows/pr_agent.yaml
SquidSpirit 1849458b71
All checks were successful
Auto Comment On PR / add_improve_comment (pull_request) Successful in 13s
Frontend CI / build (push) Successful in 1m8s
PR Title Check / pr-title-check (pull_request) Successful in 16s
BLOG-79 build: auto comment /improve command
2025-07-26 06:59:25 +08:00

21 lines
651 B
YAML

name: Auto Comment On PR
on:
pull_request:
types:
- opened
- reopened
jobs:
add_improve_comment:
runs-on: ubuntu-latest
steps:
- name: Add '/improve' comment to PR
run: |
echo "Target URL: ${{ vars.GIT_PROVIDER_URL }}/api/v1/repos/${{ gitea.repository }}/issues/${{ gitea.ref_name }}/comments"
curl --fail -X POST \
-H "Authorization: token ${{ secrets.BOT_PAT }}" \
-H "Content-Type: application/json" \
-d '{"body": "/improve"}' \
"${{ vars.GIT_PROVIDER_URL }}/api/v1/repos/${{ gitea.repository }}/issues/${{ gitea.ref_name }}/comments"