diff options
author | nikita kozlovsky <nmk@ydb.tech> | 2024-10-17 13:28:31 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-10-17 13:28:31 +0200 |
commit | 9f8e3e6d9e4a9e498b06388d5724dd7ee4a81f9a (patch) | |
tree | 3a101e9ca73fb41f01c9b6657e0d801585c5018c | |
parent | 3ad38ac44fbccebaaafe61adaaf3c6f5ed710a50 (diff) | |
download | ydb-9f8e3e6d9e4a9e498b06388d5724dd7ee4a81f9a.tar.gz |
ci: add an "external" label for issues that were opened by external users (#10551)
-rw-r--r-- | .github/workflows/label_external_issues.yml | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/.github/workflows/label_external_issues.yml b/.github/workflows/label_external_issues.yml new file mode 100644 index 0000000000..582c4e2c58 --- /dev/null +++ b/.github/workflows/label_external_issues.yml @@ -0,0 +1,22 @@ +name: Label issue from external users +on: + issues: + types: [opened] + +jobs: + label-external-issues: + name: Label issue from external user + runs-on: ubuntu-latest + # https://docs.github.com/en/graphql/reference/enums#commentauthorassociation + if: ${{ !contains(fromJson('["MEMBER", "OWNER", "COLLABORATOR"]'), github.event.issue.author_association) }} + steps: + - name: add external label + uses: actions/github-script@v7 + with: + script: | + github.rest.issues.addLabels({ + issue_number: context.issue.number, + owner: context.repo.owner, + repo: context.repo.repo, + labels: ['external'] + }) |