Generate Snake #715
This file contains 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
# 커밋 먹는 뱀 그래프 생성을 위한 GitHub Action🐍 | |
name: Generate Snake | |
# Action이 언제 구동될지 결정 | |
on: | |
schedule: | |
# 6시간마다 한 번(수정 가능) | |
- cron: "0 */6 * * *" | |
# 자동으로 Action이 실행되도록 함 | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
# 뱀 생성 | |
- uses: Platane/snk@master | |
id: snake-gif | |
with: | |
github_user_name: leejongyoung | |
# output branch에 gif, svg를 각각 생성 | |
gif_out_path: dist/github-contribution-grid-snake.gif | |
svg_out_path: dist/github-contribution-grid-snake.svg | |
- run: git status | |
# 변경사항 push | |
- name: Push changes | |
uses: ad-m/github-push-action@master | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
branch: main | |
force: true | |
- uses: crazy-max/[email protected] | |
with: | |
target_branch: output | |
build_dir: dist | |
env: | |
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }} |