Skip to content

Commit 08ef227

Browse files
authored
Merge pull request #42 from sandy3w/mixin
file structure reorganized + file path updated
2 parents 7c3c057 + a1a8f0d commit 08ef227

15 files changed

Lines changed: 54 additions & 55 deletions

File tree

.github/workflows/label_delete.yml

Lines changed: 34 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1,48 +1,48 @@
11
name: Delete Generated Labels from Specified Repos
22
on:
3-
workflow_dispatch:
3+
workflow_dispatch:
44

55
jobs:
6-
delete_labels_from_target_repos:
7-
runs-on: ubuntu-latest
6+
delete_labels_from_target_repos:
7+
runs-on: ubuntu-latest
88

9-
steps:
10-
- name: Checkout Repo
11-
uses: actions/checkout@v4
12-
with:
13-
ref: mixin
9+
steps:
10+
- name: Checkout Repo
11+
uses: actions/checkout@v4
12+
with:
13+
ref: mixin
1414

15-
- name: Set up Python
16-
uses: actions/setup-python@v4
17-
with:
18-
python-version: "3.11"
15+
- name: Set up Python
16+
uses: actions/setup-python@v4
17+
with:
18+
python-version: "3.11"
1919

20-
- name: Install Python Dependencies
21-
run: pip install requests pandas openpyxl
20+
- name: Install Python Dependencies
21+
run: pip install requests pandas openpyxl
2222

23-
- name: Install jq
24-
run: sudo apt-get update && sudo apt-get install -y jq
23+
- name: Install jq
24+
run: sudo apt-get update && sudo apt-get install -y jq
2525

26-
- name: Delete labels in target repos
27-
env:
28-
GH_TOKEN: ${{ secrets.PAT }}
29-
run: |
30-
JSON_FILE=config/repo_labels_delete.json
26+
- name: Delete labels in target repos
27+
env:
28+
GH_TOKEN: ${{ secrets.PAT }}
29+
run: |
30+
JSON_FILE=config/repo_labeler/repo_labels_delete.json
3131
32-
while read -r repo_entry; do
33-
REPO_FULL=$(echo "$repo_entry" | jq -r '.key')
34-
OWNER=$(echo "$REPO_FULL" | cut -d'/' -f1)
35-
REPO=$(echo "$REPO_FULL" | cut -d'/' -f2)
32+
while read -r repo_entry; do
33+
REPO_FULL=$(echo "$repo_entry" | jq -r '.key')
34+
OWNER=$(echo "$REPO_FULL" | cut -d'/' -f1)
35+
REPO=$(echo "$REPO_FULL" | cut -d'/' -f2)
3636
37-
echo "Deleting labels in repo: $REPO_FULL"
37+
echo "Deleting labels in repo: $REPO_FULL"
3838
39-
GH_TOKEN=${{ secrets.PAT }} REPO_OWNER=$OWNER REPO_NAME=$REPO \
40-
python API_repo_labels/scripts/label_delete.py
39+
GH_TOKEN=${{ secrets.PAT }} REPO_OWNER=$OWNER REPO_NAME=$REPO \
40+
python scripts/repo_labeler/label_delete.py
4141
42-
EXIT_CODE=$?
43-
if [ $EXIT_CODE -ne 0 ]; then
44-
echo "Deletion failed for $REPO_FULL, skipping..."
45-
fi
42+
EXIT_CODE=$?
43+
if [ $EXIT_CODE -ne 0 ]; then
44+
echo "Deletion failed for $REPO_FULL, skipping..."
45+
fi
4646
47-
sleep 5
48-
done < <(jq -c '.repos | to_entries[] | select(.value.delete_labels == true)' $JSON_FILE)
47+
sleep 5
48+
done < <(jq -c '.repos | to_entries[] | select(.value.delete_labels == true)' $JSON_FILE)

.github/workflows/labels_json_update.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name: Update Labels JSON
33
on:
44
push:
55
paths:
6-
- "data/excel_labels_data.xlsx"
6+
- "data/repo_labeler/excel_labels_data.xlsx"
77
workflow_dispatch:
88

99
jobs:
@@ -31,13 +31,13 @@ jobs:
3131
3232
- name: Run Excel to JSON conversion
3333
run: |
34-
python API_repo_labels/scripts/excel_to_json.py
34+
python scripts/repo_labeler/excel_to_json.py
3535
3636
- name: Commit and push updated JSON
3737
run: |
3838
git config user.name "github-actions"
3939
git config user.email "github-actions@github.com"
4040
41-
git add API_repo_labels/data/labels_data.json
41+
git add data/repo_labeler/labels_data.json
4242
git diff --cached --quiet || git commit -m "Auto-update labels_data.json from Excel"
4343
git push origin mixin --verbose

.github/workflows/poc_repo_fetcher.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: POC Repo Contributions Fetcher
1+
name: POC Repo Contributions Summary Fetcher
22

33
on:
44
workflow_dispatch:
@@ -40,10 +40,10 @@ jobs:
4040
env:
4141
GH_TOKEN: ${{ secrets.PAT }}
4242
run: |
43-
python issue_contributor_fetcher/poc_repo_fetcher/poc_repo_fetcher.py
43+
python scripts/contribution_summary_fetcher/poc_repo_fetcher.py
4444
4545
- name: Upload CSV Results
4646
uses: actions/upload-artifact@v4
4747
with:
4848
name: poc-results
49-
path: issue_contributor_fetcher/poc_repo_fetcher/poc_repo_fetcher_results.csv
49+
path: data/contribution_summary_fetcher/poc_repo_fetcher_results.csv

.github/workflows/repo-update.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
- name: Set up Python
1717
uses: actions/setup-python@v4
1818
with:
19-
python-version: '3.11'
19+
python-version: "3.11"
2020

2121
- name: Install Python Dependencies
2222
run: pip install requests pandas openpyxl
@@ -28,8 +28,8 @@ jobs:
2828
env:
2929
GH_TOKEN: ${{ secrets.PAT }}
3030
run: |
31-
JSON_FILE=config/target_repos_status.json
32-
TMP_FILE=config/target_repos_status.tmp.json
31+
JSON_FILE=config/repo_labeler/target_repos_status.json
32+
TMP_FILE=config/repo_labeler/target_repos_status.tmp.json
3333
UPDATED=false
3434
3535
# Use input redirection < <(...) to avoid subshell
@@ -40,7 +40,7 @@ jobs:
4040
4141
echo "Processing repo: $REPO_FULL"
4242
43-
GH_TOKEN=${{ secrets.PAT }} REPO_OWNER=$OWNER REPO_NAME=$REPO python API_repo_labels/scripts/repo_labeler.py
43+
GH_TOKEN=${{ secrets.PAT }} REPO_OWNER=$OWNER REPO_NAME=$REPO python scripts/repo_labeler/repo_labeler.py
4444
EXIT_CODE=$?
4545
4646
if [ $EXIT_CODE -eq 0 ]; then

issue_contributor_fetcher/poc_repo_fetcher/poc_target_repo.json renamed to config/contribution_summary_fetcher/poc_target_repo.json

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -470,7 +470,7 @@
470470
"color":"cccccc"
471471
},
472472
{
473-
"label_name":"x- Infrastructure: Container Orchestration",
473+
"label_name":"x- Infrastructure: Container Orchestration Platform",
474474
"description":"Container Orchestration (Usually Kubernetes)",
475475
"keywords":[
476476
"container orchestration platform"

0 commit comments

Comments
 (0)