You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by li...@apache.org on 2022/06/29 14:56:56 UTC

[pulsar] branch branch-2.10 updated: [improve][workflow] Sync the new docbot to branch-2.10 #16288

This is an automated email from the ASF dual-hosted git repository.

liuyu pushed a commit to branch branch-2.10
in repository https://gitbox.apache.org/repos/asf/pulsar.git


The following commit(s) were added to refs/heads/branch-2.10 by this push:
     new d711100dabe [improve][workflow] Sync the new docbot to branch-2.10 #16288
d711100dabe is described below

commit d711100dabe34f35d827cc61bc736baa53d5c32c
Author: Max Xu <ma...@gmail.com>
AuthorDate: Wed Jun 29 22:56:47 2022 +0800

    [improve][workflow] Sync the new docbot to branch-2.10 #16288
---
 .../{ci-documentbot.yml => ci-documentbot.yaml}    | 36 +++++++++++++---------
 1 file changed, 22 insertions(+), 14 deletions(-)

diff --git a/.github/workflows/ci-documentbot.yml b/.github/workflows/ci-documentbot.yaml
similarity index 61%
rename from .github/workflows/ci-documentbot.yml
rename to .github/workflows/ci-documentbot.yaml
index b0970773cbc..6b1a3b8f3d5 100644
--- a/.github/workflows/ci-documentbot.yml
+++ b/.github/workflows/ci-documentbot.yaml
@@ -17,7 +17,7 @@
 # under the License.
 #
 
-name: Auto Labeling
+name: Documentation Bot
 
 on:
   pull_request_target :
@@ -25,25 +25,33 @@ on:
       - opened
       - edited
       - labeled
+      - unlabeled
 
-  
-
-# A GitHub token created for a PR coming from a fork doesn't have
-# 'admin' or 'write' permission (which is required to add labels)
-# To avoid this issue, you can use the `scheduled` event and run
-# this action on a certain interval.And check the label about the
-# document.
+concurrency:
+  group: ${{ github.workflow }}-${{ github.ref }}
+  cancel-in-progress: true
 
 jobs:
-  labeling:
+  label:
     if: ${{ github.repository == 'apache/pulsar' }}
     permissions:
-      pull-requests: write 
+      pull-requests: write
     runs-on: ubuntu-latest
     steps:
-      - uses: actions/checkout@v2
+      - name: Checkout action
+        uses: actions/checkout@v3
+        with:
+          repository: apache/pulsar-test-infra
+          ref: master
 
-      - uses: apache/pulsar-test-infra/doc-label-check@master
+      - name: Set up Go
+        uses: actions/setup-go@v3
         with:
-          github-token: ${{ secrets.GITHUB_TOKEN }}
-          label-pattern: '- \[(.*?)\] ?`(.+?)`' # matches '- [x] `label`'
+          go-version: 1.18
+
+      - name: Labeling
+        uses: ./docbot
+        env:
+          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+          LABEL_WATCH_LIST: 'doc,doc-required,doc-not-needed,doc-complete'
+          LABEL_MISSING: 'doc-label-missing'
\ No newline at end of file