We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6681acd commit 7ec6a7bCopy full SHA for 7ec6a7b
.github/workflows/pr-contributor-welcome.yml
@@ -19,7 +19,15 @@ jobs:
19
if: github.event.pull_request.merged == true && github.repository == 'ant-design/ant-design'
20
runs-on: ubuntu-latest
21
steps:
22
+ - name: get commit count
23
+ id: get_commit_count
24
+ run: |
25
+ PR_AUTHOR=$(echo "${{ github.event.pull_request.user.login }}")
26
+ RESULT_DATA=$(curl -s "https://api.github.com/repos/${{ github.repository }}/commits?author=${PR_AUTHOR}&per_page=5")
27
+ DATA_LENGTH=$(echo $RESULT_DATA | jq 'if type == "array" then length else 0 end')
28
+ echo "COUNT=$DATA_LENGTH" >> $GITHUB_OUTPUT
29
- name: Comment on PR
30
+ if: steps.get_commit_count.outputs.COUNT < 3
31
uses: actions-cool/maintain-one-comment@v3
32
with:
33
token: ${{ secrets.GITHUB_TOKEN }}
0 commit comments