1
0

triage_labelled.yml 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. name: Move labelled issues to correct projects
  2. on:
  3. issues:
  4. types: [ labeled ]
  5. jobs:
  6. move_needs_info:
  7. name: Move X-Needs-Info on the triage board
  8. runs-on: ubuntu-latest
  9. if: >
  10. contains(github.event.issue.labels.*.name, 'X-Needs-Info')
  11. steps:
  12. - uses: actions/add-to-project@main
  13. id: add_project
  14. with:
  15. project-url: "https://github.com/orgs/matrix-org/projects/67"
  16. github-token: ${{ secrets.ELEMENT_BOT_TOKEN }}
  17. - name: Set status
  18. env:
  19. GITHUB_TOKEN: ${{ secrets.ELEMENT_BOT_TOKEN }}
  20. run: |
  21. gh api graphql -f query='
  22. mutation(
  23. $project: ID!
  24. $item: ID!
  25. $fieldid: ID!
  26. $columnid: String!
  27. ) {
  28. updateProjectV2ItemFieldValue(
  29. input: {
  30. projectId: $project
  31. itemId: $item
  32. fieldId: $fieldid
  33. value: {
  34. singleSelectOptionId: $columnid
  35. }
  36. }
  37. ) {
  38. projectV2Item {
  39. id
  40. }
  41. }
  42. }' -f project="PVT_kwDOAIB0Bs4AFDdZ" -f item=${{ steps.add_project.outputs.itemId }} -f fieldid="PVTSSF_lADOAIB0Bs4AFDdZzgC6ZA4" -f columnid=ba22e43c --silent