Update Blog Posts #337
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: Update Blog Posts | |
| on: | |
| push: | |
| branches: | |
| - main # 또는 워크플로우를 트리거하고 싶은 브랜치 이름 | |
| schedule: | |
| - cron: '0 0 * * *' # 매일 자정에 실행 | |
| - cron: '40 0 * * *' # 한국시간 오전 9시 40분 실행 | |
| jobs: | |
| update_blog: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v2 | |
| - name: Push changes | |
| run: | | |
| git config --global user.name 'github-actions[bot]' | |
| git config --global user.email 'github-actions[bot]@users.noreply.github.com' | |
| git push https://${{ secrets.GH_PAT }}@github.com/Fidesss/velog.git | |
| - name: Set up Python | |
| uses: actions/setup-python@v2 | |
| with: | |
| python-version: '3.x' | |
| - name: Install dependencies | |
| run: | | |
| pip install feedparser gitpython | |
| - name: Run script | |
| run: python scripts/update_blog.py |