Skip to content

Commit

Permalink
chore: workflow 라벨 설정 조건 수정 및 디버깅용 콘솔 추가
Browse files Browse the repository at this point in the history
  • Loading branch information
hjy0951 committed Jul 9, 2024
1 parent 8c33848 commit a10b94f
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/review-status-labeling.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ jobs:
});
const approvedReviews = reviewsResponse.data.filter(review => review.state === 'APPROVED');
console.log(approvedReviews);
return approvedReviews.length;
Expand All @@ -45,8 +44,6 @@ jobs:
issue_number: context.issue.number,
});
console.log(labelsResponse);
return labelsResponse.data.map(label => label.name);
- name: Apply Labels
Expand All @@ -56,8 +53,11 @@ jobs:
script: |
const labelNameList = ${{ steps.get_labels.outputs.result }};
console.log(labelNameList);
console.log(${{ steps.count_approvals.outputs.result }});
if (${{ steps.count_approvals.outputs.result }} === '0') {
if (labelNameList.includes('Approved 🆗')) {
if (labelNameList.includes('Approved 🆗') === true) {
await github.rest.issues.removeLabel({
issue_number: context.issue.number,
owner: context.repo.owner,
Expand All @@ -75,7 +75,7 @@ jobs:
});
}
} else {
if (labelNameList.includes('Approved 🆗')) {
if (labelNameList.includes('Approved 🆗') === true) {
await github.rest.issues.removeLabel({
issue_number: context.issue.number,
owner: context.repo.owner,
Expand Down

0 comments on commit a10b94f

Please sign in to comment.