File tree Expand file tree Collapse file tree 1 file changed +42
-0
lines changed
Expand file tree Collapse file tree 1 file changed +42
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Manage Repository Labels
2+
3+ on :
4+ push :
5+ paths :
6+ - " .github/workflows/manage-labels.yml"
7+ - " .github/repository-labels-data/*.json"
8+ schedule :
9+ # run every Tuesday at 3 AM UTC
10+ - cron : " 0 3 * * 2"
11+ # workflow_dispatch event allows the workflow to be triggered manually
12+ # See: https://docs.github.com/en/actions/reference/events-that-trigger-workflows#workflow_dispatch
13+ workflow_dispatch :
14+
15+ jobs :
16+ manage-labels :
17+ runs-on : ubuntu-latest
18+
19+ env :
20+ # All JSON files in this folder will be merged.
21+ SOURCE_DATA_FOLDER_PATH : .github/repository-labels-data
22+ # See: https://github.com/lannonbr/issue-label-manager-action#usage
23+ MERGED_DATA_FILE_PATH : .github/labels.json
24+
25+ steps :
26+ - uses : actions/checkout@v2
27+
28+ - name : Download universal labels data file
29+ uses :
carlosperate/[email protected] 30+ with :
31+ file-url : https://raw.githubusercontent.com/107-systems/.github/main/universal-repository-labels.json
32+ location : ${{ env.SOURCE_DATA_FOLDER_PATH }}
33+
34+ - name : Merge labels data files
35+ run : |
36+ # Merge all data files and output to the location used by lannonbr/issue-label-manager-action
37+ jq -s '.=.|add|.' "${{ env.SOURCE_DATA_FOLDER_PATH }}"/*.json > "${{ env.MERGED_DATA_FILE_PATH }}"
38+
39+ - name : Update labels
40+ 41+ env :
42+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
You can’t perform that action at this time.
0 commit comments