Update label move logic (#34026)

Split growth & integrations teams into two separate teams and add the new issues to the corresponding boards
This commit is contained in:
Murat Sutunc 2022-04-18 15:09:57 -07:00 committed by GitHub
parent f7dd836808
commit 2be88d5583
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -68,23 +68,23 @@ jobs:
}
}
}' -f project=$PROJECT_ID -f node_id=$NODE_ID
growth-and-integrations-board:
integrations-board:
runs-on: ubuntu-latest
env:
PROJECT_ID: MDExOlByb2plY3ROZXh0NDMyNg== # https://github.com/orgs/sourcegraph/projects/213
GITHUB_TOKEN: ${{ secrets.GH_PROJECTS_ACTION_TOKEN }}
steps:
- name: Get issue if relevant
if: ${{ contains(github.event.issue.labels.*.name, 'team/growth-and-integrations') }}
if: ${{ contains(github.event.issue.labels.*.name, 'team/integrations') }}
env:
NODE_ID: ${{ github.event.issue.node_id }}
run: echo 'NODE_ID='$NODE_ID >> $GITHUB_ENV
- name: Get pull request if relevant
if: ${{ contains(github.event.pull_request.labels.*.name, 'team/growth-and-integrations') }}
if: ${{ contains(github.event.pull_request.labels.*.name, 'team/integrations') }}
env:
NODE_ID: ${{ github.event.pull_request.node_id }}
run: echo 'NODE_ID='$NODE_ID >> $GITHUB_ENV
- name: Add to Growth and Integrations board
- name: Add to Integrations board
if: ${{ env.NODE_ID != '' }}
run: |
gh api graphql --header 'GraphQL-Features: projects_next_graphql' -f query='
@ -220,3 +220,30 @@ jobs:
}
}
}' -f project=$PROJECT_ID -f node_id=$NODE_ID
growth-board:
runs-on: ubuntu-latest
env:
PROJECT_ID: PN_kwDOADy5QM4ABLw3 # https://github.com/orgs/sourcegraph/projects/253
GITHUB_TOKEN: ${{ secrets.GH_PROJECTS_ACTION_TOKEN }}
steps:
- name: Get issue if relevant
if: ${{ contains(github.event.issue.labels.*.name, 'team/growth') }}
env:
NODE_ID: ${{ github.event.issue.node_id }}
run: echo 'NODE_ID='$NODE_ID >> $GITHUB_ENV
- name: Get pull request if relevant
if: ${{ contains(github.event.pull_request.labels.*.name, 'team/growth') }}
env:
NODE_ID: ${{ github.event.pull_request.node_id }}
run: echo 'NODE_ID='$NODE_ID >> $GITHUB_ENV
- name: Add to Growth board
if: ${{ env.NODE_ID != '' }}
run: |
gh api graphql --header 'GraphQL-Features: projects_next_graphql' -f query='
mutation($project:ID!, $node_id:ID!) {
addProjectNextItem(input: {projectId: $project, contentId: $node_id}) {
projectNextItem {
id
}
}
}' -f project=$PROJECT_ID -f node_id=$NODE_ID