Update stat cards 🃏 #81
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 stat cards 🃏 | |
| # Run daily at 01:00 UTC | |
| on: | |
| schedule: | |
| - cron: "0 01 * * *" | |
| workflow_dispatch: | |
| push: | |
| branches: | |
| - main | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: write | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Generate stats card (dark version) | |
| uses: readme-tools/github-readme-stats-action@v1 | |
| with: | |
| card: stats | |
| options: username=${{ github.repository_owner }}&show_icons=true&bg_color=00000000&title_color=51aeddff&text_color=ffffffff&icon_color=51aeddff&hide_border=true&card_width=200px | |
| path: images/grs-user-stats-dark.svg | |
| token: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Generate stats card (light version) | |
| uses: readme-tools/github-readme-stats-action@v1 | |
| with: | |
| card: stats | |
| options: username=${{ github.repository_owner }}&show_icons=true&bg_color=00000000&title_color=51aeddff&text_color=000000ff&icon_color=51aeddff&hide_border=true&card_width=200px | |
| path: images/grs-user-stats-light.svg | |
| token: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Generate top languages card (dark version) | |
| uses: readme-tools/github-readme-stats-action@v1 | |
| with: | |
| card: top-langs | |
| options: username=${{ github.repository_owner }}&layout=donut&bg_color=00000000&title_color=51aeddff&text_color=ffffffff&hide_border=true&card_width=200px | |
| path: images/grs-top-langs-dark.svg | |
| token: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Generate top languages card (light version) | |
| uses: readme-tools/github-readme-stats-action@v1 | |
| with: | |
| card: top-langs | |
| options: username=${{ github.repository_owner }}&layout=donut&bg_color=00000000&title_color=51aeddff&text_color=000000ff&hide_border=true&card_width=200px | |
| path: images/grs-top-langs-light.svg | |
| token: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Commit cards | |
| run: | | |
| git config user.name "github-actions[bot]" | |
| git config user.email "41898282+github-actions[bot]@users.noreply.github.com" | |
| git pull | |
| git add images/grs-*.svg | |
| git commit -m "Update README cards" || exit 0 | |
| git push |