From 139d3f337b08e1f687b72d2467cfeba1c10f39ce Mon Sep 17 00:00:00 2001 From: Feng Liyuan Date: Fri, 28 Feb 2020 21:13:46 +0800 Subject: [PATCH 01/14] Create main.yml --- .github/workflows/main.yml | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 .github/workflows/main.yml diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml new file mode 100644 index 0000000000000..01074eda572e4 --- /dev/null +++ b/.github/workflows/main.yml @@ -0,0 +1,2 @@ +- name: Licensed CI + uses: jonabc/licensed-ci@v1.4.0 From 7668fd19d902399406adc331c45f65f909f6460a Mon Sep 17 00:00:00 2001 From: Feng Liyuan Date: Fri, 28 Feb 2020 21:14:38 +0800 Subject: [PATCH 02/14] Update main.yml --- .github/workflows/main.yml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 01074eda572e4..da541354c6f49 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1,2 +1,7 @@ -- name: Licensed CI - uses: jonabc/licensed-ci@v1.4.0 +- name: Setup github/licensed + uses: jonabc/setup-licensed@v1.0.0 + with: + # The github/licensed version to install + version: + # The target install directory for the github/licensed executable + install-dir: # optional, default is /usr/local/bin From 5dfed154aec1388def892ad51585b4cfbdfbbd39 Mon Sep 17 00:00:00 2001 From: Feng Liyuan Date: Fri, 28 Feb 2020 21:16:04 +0800 Subject: [PATCH 03/14] Update main.yml --- .github/workflows/main.yml | 23 ++++++++++++++++------- 1 file changed, 16 insertions(+), 7 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index da541354c6f49..8db0664230066 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1,7 +1,16 @@ -- name: Setup github/licensed - uses: jonabc/setup-licensed@v1.0.0 - with: - # The github/licensed version to install - version: - # The target install directory for the github/licensed executable - install-dir: # optional, default is /usr/local/bin +name: 'Setup github/licensed' +description: 'Setup github/licensed for use in GitHub Actions workflows' +branding: + icon: check + color: green +inputs: + version: + description: 'The github/licensed version to install' + required: true + install-dir: + description: 'The target install directory for the github/licensed executable' + default: '/usr/local/bin' + required: false +runs: + using: 'node12' + main: 'lib/index.js' From e1a90bc10d9b2cdb9a6152041dafc7fbac779121 Mon Sep 17 00:00:00 2001 From: Feng Liyuan Date: Fri, 6 Mar 2020 16:20:09 +0800 Subject: [PATCH 04/14] Create auto_assign_project.yml --- .github/workflows/auto_assign_project.yml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 .github/workflows/auto_assign_project.yml diff --git a/.github/workflows/auto_assign_project.yml b/.github/workflows/auto_assign_project.yml new file mode 100644 index 0000000000000..0d5e9421bdd32 --- /dev/null +++ b/.github/workflows/auto_assign_project.yml @@ -0,0 +1,16 @@ +name: Auto Assign Project + +on: [issues] +env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + +jobs: + assign_one_project: + runs-on: ubuntu-latest + name: Assign to One Project + steps: + - name: Run assignment to one project + uses: srggrs/assign-one-project-github-action@1.1.0 + if: github.event.action == 'opened' && contains(github.event.issue.labels.*.name, 'component/expression') + with: + project: 'https://github.com/SunRunAway/tidb/projects/1' From 66562b5e4e1a0ea49f03926b75edbb69284c0b16 Mon Sep 17 00:00:00 2001 From: Feng Liyuan Date: Fri, 6 Mar 2020 16:21:15 +0800 Subject: [PATCH 05/14] Delete main.yml --- .github/workflows/main.yml | 16 ---------------- 1 file changed, 16 deletions(-) delete mode 100644 .github/workflows/main.yml diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml deleted file mode 100644 index 8db0664230066..0000000000000 --- a/.github/workflows/main.yml +++ /dev/null @@ -1,16 +0,0 @@ -name: 'Setup github/licensed' -description: 'Setup github/licensed for use in GitHub Actions workflows' -branding: - icon: check - color: green -inputs: - version: - description: 'The github/licensed version to install' - required: true - install-dir: - description: 'The target install directory for the github/licensed executable' - default: '/usr/local/bin' - required: false -runs: - using: 'node12' - main: 'lib/index.js' From 3a8b976ed2005a66ac0e3af19b39a03253dd1f16 Mon Sep 17 00:00:00 2001 From: Feng Liyuan Date: Fri, 6 Mar 2020 16:26:36 +0800 Subject: [PATCH 06/14] Update auto_assign_project.yml --- .github/workflows/auto_assign_project.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/auto_assign_project.yml b/.github/workflows/auto_assign_project.yml index 0d5e9421bdd32..9410d5dd52ecd 100644 --- a/.github/workflows/auto_assign_project.yml +++ b/.github/workflows/auto_assign_project.yml @@ -11,6 +11,6 @@ jobs: steps: - name: Run assignment to one project uses: srggrs/assign-one-project-github-action@1.1.0 - if: github.event.action == 'opened' && contains(github.event.issue.labels.*.name, 'component/expression') + if: github.event.action == 'labeled' && contains(github.event.issue.labels.*.name, 'component/expression') with: project: 'https://github.com/SunRunAway/tidb/projects/1' From 05f32669e65bd787df05a69a2ae38067f2f310f3 Mon Sep 17 00:00:00 2001 From: Feng Liyuan Date: Fri, 6 Mar 2020 16:32:27 +0800 Subject: [PATCH 07/14] Update auto_assign_project.yml --- .github/workflows/auto_assign_project.yml | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/.github/workflows/auto_assign_project.yml b/.github/workflows/auto_assign_project.yml index 9410d5dd52ecd..3011c470876b0 100644 --- a/.github/workflows/auto_assign_project.yml +++ b/.github/workflows/auto_assign_project.yml @@ -1,16 +1,13 @@ -name: Auto Assign Project - +name: Add a new GitHub Project card linked to a GitHub issue to the specified project column on: [issues] -env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - jobs: - assign_one_project: + github-actions-automate-projects: runs-on: ubuntu-latest - name: Assign to One Project steps: - - name: Run assignment to one project - uses: srggrs/assign-one-project-github-action@1.1.0 - if: github.event.action == 'labeled' && contains(github.event.issue.labels.*.name, 'component/expression') - with: - project: 'https://github.com/SunRunAway/tidb/projects/1' + - name: add-new-issues-to-repository-based-project-column + uses: docker://takanabe/github-actions-automate-projects:v0.0.1 + if: github.event_name == 'issues' && github.event.action == 'labeled' && contains(github.event.issue.labels.*.name, 'component/expression') + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + GITHUB_PROJECT_URL: https://github.com/SunRunAway/tidb/projects/1 + GITHUB_PROJECT_COLUMN_NAME: To do From 9312c393114f95ba0537c9a6957213a99f636304 Mon Sep 17 00:00:00 2001 From: Feng Liyuan Date: Sat, 7 Mar 2020 00:14:38 +0800 Subject: [PATCH 08/14] Create lgtm-label.yml --- .github/workflows/lgtm-label.yml | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 .github/workflows/lgtm-label.yml diff --git a/.github/workflows/lgtm-label.yml b/.github/workflows/lgtm-label.yml new file mode 100644 index 0000000000000..770bc6ad9222c --- /dev/null +++ b/.github/workflows/lgtm-label.yml @@ -0,0 +1,28 @@ +name: LGTM label +on: + pull_request_review: + types: [submitted] +env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: awact/label-action@0.1.0 + if: > + !contains(github.event.issue.labels.*.name, 'status/LGT1') && + !contains(github.event.issue.labels.*.name, 'status/LGT2') && + (contains(github.event.review.body, 'LGTM') || + contains(github.event.review.body, 'lgtm') || + contains(github.event.review.body, 'Lgtm')) + with: + ADD_LABEL: 'status/LGT1' + - uses: awact/label-action@0.1.0 + if: > + contains(github.event.issue.labels.*.name, 'status/LGT1') && + !contains(github.event.issue.labels.*.name, 'status/LGT2') && + (contains(github.event.review.body, 'LGTM') || + contains(github.event.review.body, 'lgtm') || + contains(github.event.review.body, 'Lgtm')) + with: + ADD_LABEL: 'status/LGT2' From 8c53d2070e1baa2cca2255c9ccc7eeb1360fc2f5 Mon Sep 17 00:00:00 2001 From: Feng Liyuan Date: Sat, 7 Mar 2020 00:16:03 +0800 Subject: [PATCH 09/14] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 843870de1a7e3..9d2af06f4de3e 100644 --- a/README.md +++ b/README.md @@ -66,7 +66,7 @@ Read the [Quick Start Guide](https://pingcap.com/docs/QUICKSTART), which include - [**Stack Overflow**](https://stackoverflow.com/questions/tagged/tidb) - [**User Group (Chinese)**](https://asktug.com) -## Documentation +## Documentationx + [English](https://pingcap.com/docs) + [简体中文](https://pingcap.com/docs-cn) From 485b73aa831c5b0715a243c8ef8907ddb22ef02f Mon Sep 17 00:00:00 2001 From: Feng Liyuan Date: Sat, 7 Mar 2020 00:19:53 +0800 Subject: [PATCH 10/14] Update lgtm-label.yml --- .github/workflows/lgtm-label.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/lgtm-label.yml b/.github/workflows/lgtm-label.yml index 770bc6ad9222c..b275176027269 100644 --- a/.github/workflows/lgtm-label.yml +++ b/.github/workflows/lgtm-label.yml @@ -15,7 +15,7 @@ jobs: (contains(github.event.review.body, 'LGTM') || contains(github.event.review.body, 'lgtm') || contains(github.event.review.body, 'Lgtm')) - with: + env: ADD_LABEL: 'status/LGT1' - uses: awact/label-action@0.1.0 if: > @@ -24,5 +24,5 @@ jobs: (contains(github.event.review.body, 'LGTM') || contains(github.event.review.body, 'lgtm') || contains(github.event.review.body, 'Lgtm')) - with: + env: ADD_LABEL: 'status/LGT2' From 53e6dd97a902a5612b32ed4ef0e0f99dd0236f24 Mon Sep 17 00:00:00 2001 From: Feng Liyuan Date: Sat, 7 Mar 2020 00:25:10 +0800 Subject: [PATCH 11/14] Update lgtm-label.yml --- .github/workflows/lgtm-label.yml | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/.github/workflows/lgtm-label.yml b/.github/workflows/lgtm-label.yml index b275176027269..69ce7c15d98db 100644 --- a/.github/workflows/lgtm-label.yml +++ b/.github/workflows/lgtm-label.yml @@ -8,16 +8,16 @@ jobs: build: runs-on: ubuntu-latest steps: - - uses: awact/label-action@0.1.0 + - uses: andymckay/labeler@1.0.2 if: > !contains(github.event.issue.labels.*.name, 'status/LGT1') && !contains(github.event.issue.labels.*.name, 'status/LGT2') && (contains(github.event.review.body, 'LGTM') || contains(github.event.review.body, 'lgtm') || contains(github.event.review.body, 'Lgtm')) - env: - ADD_LABEL: 'status/LGT1' - - uses: awact/label-action@0.1.0 + with: + add-labels: 'status/LGT1' + - uses: andymckay/labeler@1.0.2 if: > contains(github.event.issue.labels.*.name, 'status/LGT1') && !contains(github.event.issue.labels.*.name, 'status/LGT2') && @@ -25,4 +25,5 @@ jobs: contains(github.event.review.body, 'lgtm') || contains(github.event.review.body, 'Lgtm')) env: - ADD_LABEL: 'status/LGT2' + add-labels: 'status/LGT2' + remove-labels: 'status/LGT1' From 0fe0ceffc3a4e1d9d6ef32c9fba69b9cb7cf3c2f Mon Sep 17 00:00:00 2001 From: Feng Liyuan Date: Sat, 7 Mar 2020 00:30:54 +0800 Subject: [PATCH 12/14] Update lgtm-label.yml --- .github/workflows/lgtm-label.yml | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/workflows/lgtm-label.yml b/.github/workflows/lgtm-label.yml index 69ce7c15d98db..3c1164277a2ab 100644 --- a/.github/workflows/lgtm-label.yml +++ b/.github/workflows/lgtm-label.yml @@ -8,7 +8,7 @@ jobs: build: runs-on: ubuntu-latest steps: - - uses: andymckay/labeler@1.0.2 + - uses: buildsville/add-remove-label@v1 if: > !contains(github.event.issue.labels.*.name, 'status/LGT1') && !contains(github.event.issue.labels.*.name, 'status/LGT2') && @@ -16,7 +16,8 @@ jobs: contains(github.event.review.body, 'lgtm') || contains(github.event.review.body, 'Lgtm')) with: - add-labels: 'status/LGT1' + label: 'status/LGT1' + type: add - uses: andymckay/labeler@1.0.2 if: > contains(github.event.issue.labels.*.name, 'status/LGT1') && @@ -25,5 +26,5 @@ jobs: contains(github.event.review.body, 'lgtm') || contains(github.event.review.body, 'Lgtm')) env: - add-labels: 'status/LGT2' - remove-labels: 'status/LGT1' + label: 'status/LGT2' + type: add From 4121e6c6f765479208e618b3efd4bc121d04c180 Mon Sep 17 00:00:00 2001 From: Feng Liyuan Date: Sat, 7 Mar 2020 00:31:15 +0800 Subject: [PATCH 13/14] Update lgtm-label.yml --- .github/workflows/lgtm-label.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/lgtm-label.yml b/.github/workflows/lgtm-label.yml index 3c1164277a2ab..d83f6e9cac629 100644 --- a/.github/workflows/lgtm-label.yml +++ b/.github/workflows/lgtm-label.yml @@ -18,7 +18,7 @@ jobs: with: label: 'status/LGT1' type: add - - uses: andymckay/labeler@1.0.2 + - uses: buildsville/add-remove-label@v1 if: > contains(github.event.issue.labels.*.name, 'status/LGT1') && !contains(github.event.issue.labels.*.name, 'status/LGT2') && From 39e9361b10d23729d57eb83c0ac5e5523089c952 Mon Sep 17 00:00:00 2001 From: Feng Liyuan Date: Sat, 7 Mar 2020 00:34:20 +0800 Subject: [PATCH 14/14] Update lgtm-label.yml --- .github/workflows/lgtm-label.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/lgtm-label.yml b/.github/workflows/lgtm-label.yml index d83f6e9cac629..69a76d5c317e5 100644 --- a/.github/workflows/lgtm-label.yml +++ b/.github/workflows/lgtm-label.yml @@ -16,6 +16,7 @@ jobs: contains(github.event.review.body, 'lgtm') || contains(github.event.review.body, 'Lgtm')) with: + token: ${{secrets.GITHUB_TOKEN}} label: 'status/LGT1' type: add - uses: buildsville/add-remove-label@v1 @@ -26,5 +27,6 @@ jobs: contains(github.event.review.body, 'lgtm') || contains(github.event.review.body, 'Lgtm')) env: + token: ${{secrets.GITHUB_TOKEN}} label: 'status/LGT2' type: add