Skip to content

Create a PR to with the following changes... (Warning: this should happen right after creating the release branch. If this is deferred till later, the and branches can diverge significantly, which may cause merge conflicts.) #6650

Create a PR to with the following changes... (Warning: this should happen right after creating the release branch. If this is deferred till later, the and branches can diverge significantly, which may cause merge conflicts.)

Create a PR to with the following changes... (Warning: this should happen right after creating the release branch. If this is deferred till later, the and branches can diverge significantly, which may cause merge conflicts.) #6650

Workflow file for this run

name: Assign DS issue to someone
on:
issues:
types: [opened]
permissions:
issues: write
jobs:
assignIssue:
name: Assign Issue to Someone
runs-on: ubuntu-latest
if: github.repository == 'microsoft/vscode-jupyter'
steps:
- uses: actions/checkout@v3
- name: Created internally
id: internal
env:
ISSUE_OWNER: ${{github.event.issue.user.login}}
run: |
echo ::set-output name=result::$(node -p -e "['amunger', 'DonJayamanne', 'minsa110', 'rebornix', 'roblourens', 'kieferrm'].filter(item => process.env.ISSUE_OWNER.toLowerCase() === item.toLowerCase()).length > 0 ? 1 : 0")
shell: bash
- name: Should we proceed
id: proceed
env:
ISSUE_LABELS: ${{toJson(github.event.issue.labels)}}
ISSUE_ASSIGNEES: ${{toJson(github.event.issue.assignees)}}
ISSUE_IS_INTERNAL: ${{steps.internal.outputs.result}}
run: |
echo ::set-output name=result::$(node -p -e "process.env.ISSUE_IS_INTERNAL === '0' && JSON.parse(process.env.ISSUE_ASSIGNEES).length === 0 ? 1 : 0")
shell: bash
- name: Day of week
if: steps.proceed.outputs.result == 1
id: day
run: |
echo ::set-output name=number::$(node -p -e "new Date().getDay()")
shell: bash
- name: Hour of day
if: steps.proceed.outputs.result == 1
id: hour
run: |
echo ::set-output name=hour::$(node -p -e "(new Date().getUTCHours() - 7)%24")
shell: bash
- name: Week Number
if: steps.proceed.outputs.result == 1
id: week
run: |
echo ::set-output name=odd::$(node .github/workflows/week.js)
shell: bash
- name: Print day and week
if: steps.proceed.outputs.result == 1
run: |
echo ${{steps.day.outputs.number}}
echo ${{steps.week.outputs.odd}}
echo ${{steps.hour.outputs.hour}}
shell: bash
- name: Saturday (Don)
if: steps.proceed.outputs.result == 1 && steps.day.outputs.number == 6
uses: actions/[email protected]
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
github.rest.issues.addAssignees({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
assignees: ['DonJayamanne']
})
- name: Sunday (Don)
if: steps.proceed.outputs.result == 1 && steps.day.outputs.number == 0
uses: actions/[email protected]
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
github.rest.issues.addAssignees({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
assignees: ['DonJayamanne']
})
- name: Monday (Aaron)
if: steps.proceed.outputs.result == 1 && steps.day.outputs.number == 1 && steps.hour.outputs.hour < 16
uses: actions/[email protected]
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
github.rest.issues.addAssignees({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
assignees: ['amunger']
})
- name: Tuesday (Rob)
if: steps.proceed.outputs.result == 1 && (steps.day.outputs.number == 1 && steps.hour.outputs.hour >= 16) || (steps.day.outputs.number == 2 && steps.hour.outputs.hour < 16)
uses: actions/[email protected]
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
github.rest.issues.addAssignees({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
assignees: ['roblourens ']
})
- name: Wednesday (Don)
if: steps.proceed.outputs.result == 1 && (steps.day.outputs.number == 2 && steps.hour.outputs.hour >= 16) || (steps.day.outputs.number == 3 && steps.hour.outputs.hour < 16)
uses: actions/[email protected]
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
github.rest.issues.addAssignees({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
assignees: ['DonJayamanne']
})
- name: Thursday (Peng)
if: steps.proceed.outputs.result == 1 && (steps.day.outputs.number == 3 && steps.hour.outputs.hour >= 16) || (steps.day.outputs.number == 4 && steps.hour.outputs.hour < 16)
uses: actions/[email protected]
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
github.rest.issues.addAssignees({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
assignees: ['rebornix']
})
- name: Friday (Aaron)
if: steps.proceed.outputs.result == 1 && (steps.day.outputs.number == 4 && steps.hour.outputs.hour >= 16) || (steps.day.outputs.number == 5)
uses: actions/[email protected]
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
github.rest.issues.addAssignees({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
assignees: ['amunger']
})