Skip to content

[Snyk] Security upgrade express from 4.17.1 to 4.19.2 #7

[Snyk] Security upgrade express from 4.17.1 to 4.19.2

[Snyk] Security upgrade express from 4.17.1 to 4.19.2 #7

name: Triage new issue comments
# **What it does**:
# **Why we have it**:
# **Who does it impact**:
on:
issue_comment:
types:
- created
jobs:
triage-issue-comments:
if: github.repository == 'github/docs' && github.event.issue.pull_request == null
runs-on: ubuntu-latest
steps:
- name: Check if the event originated from a team member
uses: actions/github-script@2b34a689ec86a68d8ab9478298f91d5401337b7d
id: is-internal-contributor
with:
github-token: ${{secrets.GITHUB_TOKEN}}
result-encoding: string
script: |
const repo = context.payload.repository.name
const org = context.payload.repository.owner.login
const actor = context.actor
let collaboratorStatus = ''
try {
collaboratorStatus = await github.request('GET /repos/{owner}/{repo}/collaborators/{username}', {
owner: org,
repo: repo,
username: actor
})
console.log(`This issue was commented on by a Hubber.`)
return 'true'
} catch (error) {
console.log(`This issue was commented on by an external contributor.`)
return 'false'
}
- name: Label issues with new comments with 'triage'
uses: rachmari/labeler@832d42ec5523f3c6d46e8168de71cd54363e3e2e
if: (steps.is-internal-contributor.outputs.result == 'false')
with:
repo-token: '${{ secrets.GITHUB_TOKEN }}'
add-labels: 'triage'
- name: Triage to project board
uses: rachmari/actions-add-new-issue-to-column@1a459ef92308ba7c9c9dc2fcdd72f232495574a9
with:
action-token: ${{ secrets.GITHUB_TOKEN }}
project-url: 'https://github.com/github/docs/projects/1'
column-name: 'Triage'