From f0211119263921ac65d673e86ba4c6e3679f53f3 Mon Sep 17 00:00:00 2001 From: Oscar Vestlie Date: Fri, 9 Jun 2023 10:35:37 -0700 Subject: [PATCH 1/5] Update README.md Testing coverage --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index faef7f104bc9a..0e03dee658704 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Cobalt [![Build Matrix](https://img.shields.io/badge/-Build%20Matrix-blueviolet)](https://github.com/youtube/cobalt/blob/main/BUILD_STATUS.md) -[![codecov](https://codecov.io/github/youtube/cobalt/branch/main/graph/badge.svg?token=QZY8I830S6)](https://codecov.io/github/youtube/cobalt) +[![codecov](https://codecov.io/github/youtube/cobalt/branch/main/graph/badge.svg?token=QZY8I830S6)](https://codecov.io/github/youtube/cobalt_sandbox) [![lint](https://github.com/youtube/cobalt/actions/workflows/lint.yaml/badge.svg?branch=main&event=push)](https://github.com/youtube/cobalt/actions/workflows/lint.yaml?query=event%3Apush+branch%3Amain) [![java](https://github.com/youtube/cobalt/actions/workflows/gradle.yaml/badge.svg?branch=main&event=push)](https://github.com/youtube/cobalt/actions/workflows/gradle.yaml?query=event%3Apush+branch%3Amain) [![python](https://github.com/youtube/cobalt/actions/workflows/pytest.yaml/badge.svg?branch=main&event=push)](https://github.com/youtube/cobalt/actions/workflows/pytest.yaml?query=event%3Apush+branch%3Amain) \ From df1c3e85098ff0c4e8cf8b058326c53fa527a180 Mon Sep 17 00:00:00 2001 From: Oscar Vestlie Date: Fri, 9 Jun 2023 10:38:24 -0700 Subject: [PATCH 2/5] Add codecov token param Testing codedov --- .github/actions/on_host_test/action.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/actions/on_host_test/action.yaml b/.github/actions/on_host_test/action.yaml index 1d6602ebf73b0..22d871be88760 100644 --- a/.github/actions/on_host_test/action.yaml +++ b/.github/actions/on_host_test/action.yaml @@ -106,6 +106,8 @@ runs: path: ${{env.TEST_REPORT_FILE}} - name: Upload coverage html report if: ${{matrix.shard}} == 'coverage' + env: + CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} uses: actions/upload-artifact@v3 with: name: coverage-report From b08bebc12624422a3eab3b0f3f1fbb5d0431eab8 Mon Sep 17 00:00:00 2001 From: Oscar Vestlie Date: Fri, 9 Jun 2023 11:02:39 -0700 Subject: [PATCH 3/5] Revert "Add codecov token param" This reverts commit df1c3e85098ff0c4e8cf8b058326c53fa527a180. --- .github/actions/on_host_test/action.yaml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/actions/on_host_test/action.yaml b/.github/actions/on_host_test/action.yaml index 22d871be88760..1d6602ebf73b0 100644 --- a/.github/actions/on_host_test/action.yaml +++ b/.github/actions/on_host_test/action.yaml @@ -106,8 +106,6 @@ runs: path: ${{env.TEST_REPORT_FILE}} - name: Upload coverage html report if: ${{matrix.shard}} == 'coverage' - env: - CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} uses: actions/upload-artifact@v3 with: name: coverage-report From f79b4aeffa80fbb8312f3085554c0755fb332938 Mon Sep 17 00:00:00 2001 From: Andrew Savage Date: Wed, 28 Jun 2023 06:41:18 -0700 Subject: [PATCH 4/5] Add workflow to auto label PRs (#465) --- .github/workflows/auto_label_pr.yaml | 35 ++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 .github/workflows/auto_label_pr.yaml diff --git a/.github/workflows/auto_label_pr.yaml b/.github/workflows/auto_label_pr.yaml new file mode 100644 index 0000000000000..a8acac8edc840 --- /dev/null +++ b/.github/workflows/auto_label_pr.yaml @@ -0,0 +1,35 @@ +name: PR Auto Label + +on: + pull_request_target: + types: + - opened + - reopened + +concurrency: + group: '${{ github.workflow }}-${{ github.event_name }} @ ${{ github.event.pull_request.number || github.sha }}' + cancel-in-progress: true + +jobs: + assign-reviewer: + runs-on: ubuntu-latest + permissions: + pull-requests: write + steps: + - name: Check if PR author is outside collaborator and assign reviewer + env: + PR_AUTHOR_LOGIN: ${{ github.event.pull_request.user.login }} + REPO_NAME: ${{ github.event.repository.full_name }} + PR_NUMBER: ${{ github.event.number }} + run: | + PERMISSION_LEVEL=$(curl -s -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \ + "https://api.github.com/repos/$REPO_NAME/collaborators/$PR_AUTHOR_LOGIN/permission" | jq -r .role_name) + + if [ "$PERMISSION_LEVEL" == "none" ] || [ "$PERMISSION_LEVEL" == "read" ]; then + echo "PR author is an outside collaborator. Adding label..." + + curl -s -X POST -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \ + -H "Accept: application/vnd.github.v3+json" \ + -d '["outside collaborator"]' \ + "https://api.github.com/repos/$REPO_NAME/issues/$PR_NUMBER/labels" + fi From af86f7216816f638d6debfe7647de4b8d6db8968 Mon Sep 17 00:00:00 2001 From: Andrew Savage Date: Wed, 28 Jun 2023 06:43:17 -0700 Subject: [PATCH 5/5] Test external commit --- AUTHORS | 1 + 1 file changed, 1 insertion(+) diff --git a/AUTHORS b/AUTHORS index 99cc139cea0f3..964a8bf5aecac 100644 --- a/AUTHORS +++ b/AUTHORS @@ -7,6 +7,7 @@ # Organization # # See python fnmatch module documentation for more information. +# Test external change The Chromium Authors <*@chromium.org> Google Inc. <*@google.com>