LLM 토큰 사용량 집계 로직 TokenUtils 클래스로 분리 #89
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Notify Telegram on PR Events | |
| on: | |
| pull_request: | |
| types: [opened, closed] | |
| jobs: | |
| notify: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Send Telegram Message on PR Open | |
| if: github.event_name == 'pull_request' && github.event.action == 'opened' | |
| env: | |
| TELEGRAM_BOT_TOKEN: ${{ secrets.TELEGRAM_BOT_TOKEN }} | |
| TELEGRAM_CHAT_ID: ${{ secrets.TELEGRAM_CHAT_ID }} | |
| PR_TITLE: ${{ github.event.pull_request.title }} | |
| PR_URL: ${{ github.event.pull_request.html_url }} | |
| PR_AUTHOR: ${{ github.event.pull_request.user.login }} | |
| run: | | |
| MESSAGE="📢 새로운 PR 등록!%0A%0A제목: $PR_TITLE%0A작성자: $PR_AUTHOR%0A링크: $PR_URL" | |
| curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/sendMessage" \ | |
| -d chat_id="$TELEGRAM_CHAT_ID" \ | |
| -d text="$MESSAGE" | |
| - name: Send Telegram Message on PR Approved | |
| if: github.event_name == 'pull_request' && github.event.action == 'closed' && github.event.pull_request.merged | |
| env: | |
| TELEGRAM_BOT_TOKEN: ${{ secrets.TELEGRAM_BOT_TOKEN }} | |
| TELEGRAM_CHAT_ID: ${{ secrets.TELEGRAM_CHAT_ID }} | |
| PR_TITLE: ${{ github.event.pull_request.title }} | |
| PR_URL: ${{ github.event.pull_request.html_url }} | |
| PR_AUTHOR: ${{ github.event.pull_request.user.login }} | |
| REVIEWER: ${{ github.event.review.user.login }} | |
| run: | | |
| MESSAGE="✅ PR이 병합되었습니다! %0A%0A제목: $PR_TITLE%0A작성자: $PR_AUTHOR%0A리뷰어: $REVIEWER%0A링크: $PR_URL" | |
| curl -s -X POST "https://api.telegram.org/bot$TELEGRAM_BOT_TOKEN/sendMessage" \ | |
| -d chat_id="$TELEGRAM_CHAT_ID" \ | |
| -d text="$MESSAGE" |