|
| 1 | +name: Unassign stale issue assignments |
| 2 | + |
| 3 | +on: |
| 4 | + schedule: |
| 5 | + - cron: 4 12 * * * |
| 6 | + workflow_dispatch: |
| 7 | + |
| 8 | +jobs: |
| 9 | + unassign_issues: |
| 10 | + if: github.repository_owner == 'JabRef' |
| 11 | + runs-on: ubuntu-latest |
| 12 | + permissions: |
| 13 | + issues: write |
| 14 | + outputs: |
| 15 | + unassigned_issues: ${{ steps.unassign.outputs.unassigned_issues || '[]' }} |
| 16 | + steps: |
| 17 | + - name: Unassign stale assignments |
| 18 | + id: unassign |
| 19 | + uses: takanome-dev/assign-issue-action@edge |
| 20 | + with: |
| 21 | + github_token: '${{ secrets.GITHUB_TOKEN }}' |
| 22 | + reminder_comment: | |
| 23 | + ### ⏰ Assignment Reminder |
| 24 | +
|
| 25 | + Hi @{{ handle }}, this is a friendly reminder about your assignment to this issue. |
| 26 | +
|
| 27 | + > [!WARNING] |
| 28 | + > This issue will be **automatically unassigned** in **{{ days_remaining }} days** if there's no activity. |
| 29 | +
|
| 30 | + Remember that you can ask the [JabRef Guru](https://gurubase.io/g/jabref) or [DeepWiki](https://deepwiki.com/JabRef/jabref) about anything regarding JabRef. |
| 31 | + Additionally, our contributing guide has [hints on creating a pull request](https://github.com/JabRef/jabref/blob/main/CONTRIBUTING.md#pull-request-process) and a link to our Gitter chat. |
| 32 | +
|
| 33 | + <details open> |
| 34 | + <summary>How to keep your assignment</summary> |
| 35 | +
|
| 36 | + \ |
| 37 | + If you are working on it, you can prevent automatic unassignment by: |
| 38 | +
|
| 39 | + - Submitting a [draft pull request](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-pull-requests#draft-pull-requests) with your progress within {{ days_remaining }} days |
| 40 | + - Asking for the **{{{ pin_label }}}** label if you need more time |
| 41 | + </details> |
| 42 | +
|
| 43 | + We appreciate your contribution and are here to help if needed! |
| 44 | + days_until_unassign: 21 |
| 45 | + unassigned_comment: | |
| 46 | + ### 📋 Assignment Update |
| 47 | +
|
| 48 | + Hi @{{ handle }}, due to inactivity, you have been unassigned from this issue. |
| 49 | +
|
| 50 | + <details> |
| 51 | + <summary>Next steps</summary> |
| 52 | +
|
| 53 | + \ |
| 54 | + **If you still want to work on this:** |
| 55 | + - Submit a pull request showing your current state. You will be automatically assigned again. |
| 56 | + - Ask a maintainer to assign you again. |
| 57 | + </details> |
| 58 | + - name: Print unassigned issues |
| 59 | + run: > |
| 60 | + echo "Unassigned issues: ${{ steps.unassign.outputs.unassigned_issues }}" |
| 61 | +
|
| 62 | + move_unassigned_issues: |
| 63 | + needs: unassign_issues |
| 64 | + if: ${{ needs.unassign_issues.outputs.unassigned_issues != '[]' }} |
| 65 | + runs-on: ubuntu-latest |
| 66 | + strategy: |
| 67 | + matrix: |
| 68 | + issue_number: ${{ fromJson(needs.unassign_issues.outputs.unassigned_issues) }} |
| 69 | + steps: |
| 70 | + - name: Move issue to "Free to take" in "Good First Issues" |
| 71 | + uses: m7kvqbe1/github-action-move-issues/@main |
| 72 | + with: |
| 73 | + github-token: ${{ secrets.GH_TOKEN_ACTION_MOVE_ISSUE }} |
| 74 | + project-url: "https://github.com/orgs/JabRef/projects/5" |
| 75 | + target-labels: "📍 Assigned" |
| 76 | + target-column: "Free to take" |
| 77 | + ignored-columns: "" |
| 78 | + default-column: "Free to take" |
| 79 | + issue-number: ${{ matrix.issue_number }} |
| 80 | + skip-if-not-in-project: true |
| 81 | + - name: Move issue to "Free to take" in "Candidates for University Projects" |
| 82 | + uses: m7kvqbe1/github-action-move-issues/@main |
| 83 | + with: |
| 84 | + github-token: ${{ secrets.GH_TOKEN_ACTION_MOVE_ISSUE }} |
| 85 | + project-url: "https://github.com/orgs/JabRef/projects/3" |
| 86 | + target-labels: "📍 Assigned" |
| 87 | + target-column: "Free to take" |
| 88 | + ignored-columns: "" |
| 89 | + default-column: "Free to take" |
| 90 | + issue-number: ${{ matrix.issue_number }} |
| 91 | + skip-if-not-in-project: true |
0 commit comments