update labels based on other labels

fc151284e4b4b3c8ced5d7ff4576b172e275e3b3

Wolfsblvt <wolfsblvt@gmail.com>

1 files changed, +45 -7Ignore whitespace
.github/workflows/issues-auto-manager.yml+45 -7
@@ -5,16 +5,11 @@ on:
55 types: [opened, edited, labeled, unlabeled]
66
77jobs:
8- manage-issues:
8+ issue-label-on-content:
9- name: Manage Issues
9+ name: Auto-Label Issues (Based on Issue Content)
1010 runs-on: ubuntu-latest
1111
1212 steps:
13- - name: Checkout Repository
14- # Checkout
15- # https://github.com/marketplace/actions/checkout
16- uses: actions/checkout@v4
17-
1813 - name: Auto-Label Issues (Based on Issue Content)
1914 # Issue Labeler
2015 # https://github.com/marketplace/actions/regex-issue-labeler
@@ -24,6 +19,49 @@ jobs:
2419 enable-versioned-regex: 0
2520 repo-token: ${{ secrets.BOT_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
2621
22+ issue-label-on-labels:
23+ name: Auto-Label Issues (Based on Issue Labels)
24+ runs-on: ubuntu-latest
25+
26+ steps:
27+ # βœ… Auto-Add "πŸ‘ Approved / Nice-to-Have" when specific labels are added
28+ - name: Add "πŸ‘ Approved / Nice-to-Have" for relevant labels
29+ if: contains(fromJSON('["πŸ‘©β€πŸ’» Good First Issue", "πŸ™ Help Wanted", "πŸͺ² Confirmed", "⚠️ High Priority", "❕ Medium Priority", "πŸ’€ Low Priority"]'), github.event.label.name)
30+ uses: actions-cool/issues-helper@v3
31+ with:
32+ actions: 'add-labels'
33+ token: ${{ secrets.BOT_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
34+ labels: 'πŸ‘ Approved / Nice-to-Have'
35+
36+ # ❌ Remove "πŸ§‘β€πŸ’» In Progress" when specific labels are added
37+ - name: Remove "πŸ§‘β€πŸ’» In Progress" when PR is marked done or stale
38+ if: contains(fromJSON('["βœ… Done", "βœ… Done (staging)", "⚰️ Stale", "❌ wontfix"]'), github.event.label.name)
39+ uses: actions-cool/issues-helper@v3
40+ with:
41+ actions: 'remove-labels'
42+ token: ${{ secrets.BOT_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
43+ labels: 'πŸ§‘β€πŸ’» In Progress'
44+
45+ # ❌ Remove "πŸ€” Unsure" and "πŸ€” Under Consideration" when "❌ wontfix" is added
46+ - name: Remove "πŸ€” Unsure" and "πŸ€” Under Consideration" when "❌ wontfix" is added
47+ if: github.event.label.name == '❌ wontfix'
48+ uses: actions-cool/issues-helper@v3
49+ with:
50+ actions: 'remove-labels'
51+ token: ${{ secrets.BOT_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
52+ labels: 'πŸ€” Unsure,πŸ€” Under Consideration'
53+
54+ issue-auto-comments:
55+ name: Post Issue Comments Based on Labels
56+ needs: [issue-label-on-content, issue-label-on-labels]
57+ runs-on: ubuntu-latest
58+
59+ steps:
60+ - name: Checkout Repository
61+ # Checkout
62+ # https://github.com/marketplace/actions/checkout
63+ uses: actions/checkout@v4
64+
2765 - name: Post Issue Comments Based on Labels
2866 # Label Commenter
2967 # https://github.com/marketplace/actions/label-commenter