Generate Snake #527
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: Generate Snake | |
| # Controls when the action will run | |
| on: | |
| # Triggers the workflow on schedule (every 6 hours) | |
| schedule: | |
| - cron: "0 */6 * * *" | |
| # Allows you to run this workflow manually | |
| workflow_dispatch: | |
| # A workflow run is made up of one or more jobs | |
| jobs: | |
| generate: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 10 | |
| steps: | |
| # Step 1: Checkout repository | |
| - name: Checkout | |
| uses: actions/checkout@v3 | |
| # Step 2: Generate the snake files | |
| - name: Generate github-contribution-grid-snake.svg | |
| uses: Platane/snk/svg-only@v3 | |
| with: | |
| github_user_name: Codealpha07 | |
| outputs: | | |
| dist/github-contribution-grid-snake.svg | |
| dist/github-contribution-grid-snake-dark.svg?palette=github-dark | |
| # Step 3: Push the content to the output branch | |
| - name: Push github-contribution-grid-snake.svg to the output branch | |
| uses: crazy-max/ghaction-github-pages@v3.1.0 | |
| with: | |
| target_branch: output | |
| build_dir: dist | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |