Skip to content

Commit

Permalink
chore(ci): Dispatch documentation notifications upon label added/remo…
Browse files Browse the repository at this point in the history
…ved (#1404)

* chore(ci): Dispatch documentation notifications upon label added/removed

* use github labeler at commit with my fixes

* switch back to master branch
  • Loading branch information
phated authored Jun 5, 2023
1 parent a40a590 commit f078188
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 37 deletions.
32 changes: 0 additions & 32 deletions .github/workflows/label_docs.yml

This file was deleted.

31 changes: 26 additions & 5 deletions .github/workflows/labeler.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ on:
- opened
- reopened
- edited
- synchronize

permissions:
pull-requests: write
Expand All @@ -15,10 +14,32 @@ jobs:
triage:
runs-on: ubuntu-latest
steps:
- uses: github/[email protected]
# We continue-on-error because the action is buggy and tries to remove labels when they don't exist
continue-on-error: true
- name: Label pull request
# We can switch hash to release number once it is tagged
uses: github/issue-labeler@6ae80f5cf189fd96d96a4a4125c60e87cba0578d
id: issue-labeler
with:
repo-token: "${{ secrets.GITHUB_TOKEN }}"
repo-token: ${{ secrets.GITHUB_TOKEN }}
configuration-path: .github/labeler.yml
enable-versioned-regex: 0
sync-labels: 1

- name: Create documentation issue
if: ${{ steps.issue-labeler.outputs.labels-added }}
uses: benc-uk/workflow-dispatch@v1
with:
workflow: new-migrated-issue.yml
repo: noir-lang/docs
ref: master
token: ${{ secrets.DOCS_REPO_TOKEN }}
inputs: '{ "pr-number": "${{ github.event.pull_request.number }}" }'

- name: Close documentation issue
if: ${{ steps.issue-labeler.outputs.labels-removed }}
uses: benc-uk/workflow-dispatch@v1
with:
workflow: delete-migrated-issue.yml
repo: noir-lang/docs
ref: master
token: ${{ secrets.DOCS_REPO_TOKEN }}
inputs: '{ "pr-number": "${{ github.event.pull_request.number }}" }'

0 comments on commit f078188

Please sign in to comment.