Tpetra: This is only a test #13
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Auto assign MueLu or Tpetra labeled or titled issues to MueLu or Tpetra Projects | |
on: | |
issues: | |
types: [opened, labeled] | |
permissions: | |
contents: read | |
jobs: | |
assign_one_project: | |
permissions: | |
issues: write # for actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1 | |
repository-projects: write # for actions/add-to-project to assign issues and PRs to repo project | |
name: Assign to MueLu or Tpetra Project | |
runs-on: ubuntu-latest | |
steps: | |
- name: Add MueLu Label | |
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1 | |
if: contains(github.event.issue.title, 'MueLu') | |
with: | |
script: | | |
github.rest.issues.addLabels({ | |
issue_number: context.issue.number, | |
owner: context.repo.owner, | |
repo: context.repo.repo, | |
labels: ["pkg: MueLu"] | |
}) | |
- name: Add Tpetra Label | |
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1 | |
if: contains(github.event.issue.title, 'Tpetra') | |
with: | |
script: | | |
github.rest.issues.addLabels({ | |
issue_number: context.issue.number, | |
owner: context.repo.owner, | |
repo: context.repo.repo, | |
labels: ["pkg: Tpetra"] | |
}) | |
- name: Add to MueLu Project | |
uses: actions/add-to-project@244f685bbc3b7adfa8466e08b698b5577571133e # 1.0.2 | |
if: contains(github.event.label.name, 'MueLu') || contains(github.event.issue.title, 'MueLu') | |
with: | |
project-url: https://github.com/orgs/muelu/projects/4 | |
github-token: ${{ secrets.ADD_TO_PROJECT_TOKEN }} | |
- name: Add to Tpetra Project | |
uses: actions/add-to-project@244f685bbc3b7adfa8466e08b698b5577571133e # 1.0.2 | |
if: contains(github.event.label.name, 'Tpetra') || contains(github.event.issue.title, 'Tpetra') | |
with: | |
project-url: https://github.com/orgs/muelu/projects/4 | |
github-token: ${{ secrets.ADD_TO_PROJECT_TOKEN }} | |