Skip to content

Commit 7218b15

Browse files
authored
fix: 충돌문제를 해결하기 위해 PR을 올릴 때 작동하는 것이 아닌 PR이 머지되었을 때 작동하도록 수정
1 parent b5320f2 commit 7218b15

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

.github/workflows/update_challenge_progress.yml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,16 +2,18 @@ name: Update Challenge Progress
22

33
on:
44
pull_request:
5-
types: [opened, edited, reopened]
5+
types:
6+
- closed
67

78
jobs:
89
update_progress:
10+
if: github.event.pull_request.merged == true
911
runs-on: ubuntu-latest
1012
steps:
1113
- name: Checkout Repository
1214
uses: actions/checkout@v3
1315
with:
14-
ref: ${{ github.head_ref }}
16+
ref: main
1517
fetch-depth: 0
1618

1719
- name: Set up Python
@@ -43,7 +45,7 @@ jobs:
4345
cd _MonthlyChallenges
4446
git add scoreboard.json DASHBOARD.md HISTORY.md
4547
git commit -m "Update challenge progress dashboard" || echo "No changes to commit"
46-
git push origin ${{ github.head_ref }}
48+
git push origin main
4749
4850
- name: Post PR Comment with progress
4951
if: github.event_name == 'pull_request'

0 commit comments

Comments
 (0)