Merge pull request #1 from pacnpal/copilot/refactor-github-actions-flow

This commit is contained in:
pacnpal
2026-01-17 12:43:58 -05:00
committed by GitHub
4 changed files with 63 additions and 2 deletions

View File

@@ -0,0 +1,40 @@
name: Update README Stats
on:
schedule:
- cron: "0 0 * * *" # Runs once daily at midnight
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v4
- name: Generate stats card
uses: readme-tools/github-readme-stats-action@v1
with:
card: stats
options: username=${{ github.repository_owner }}&show_icons=true&theme=radical
path: profile/stats.svg
token: ${{ secrets.GITHUB_TOKEN }}
- name: Generate top languages card
uses: readme-tools/github-readme-stats-action@v1
with:
card: top-langs
options: username=${{ github.repository_owner }}&layout=compact&theme=radical
path: profile/top-langs.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 add profile/*.svg
git commit -m "Update README stats cards" || exit 0
git push

View File

@@ -7,9 +7,9 @@
#### 📈 GitHub Stats
![pacnpal's GitHub stats](https://github-readme-stats.vercel.app/api?username=pacnpal&show_icons=true&theme=radical)
![pacnpal's GitHub stats](./profile/stats.svg)
![Top Langs](https://github-readme-stats.vercel.app/api/top-langs/?username=pacnpal&layout=compact&theme=radical)
![Top Langs](./profile/top-langs.svg)
---

9
profile/stats.svg Normal file
View File

@@ -0,0 +1,9 @@
<svg xmlns="http://www.w3.org/2000/svg" width="495" height="195" viewBox="0 0 495 195" fill="none">
<style>
text { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Helvetica', 'Arial', sans-serif; }
</style>
<rect width="495" height="195" fill="#141321" rx="4.5"/>
<text x="247.5" y="97.5" text-anchor="middle" fill="#fff" font-size="14">
GitHub stats card will be generated by workflow
</text>
</svg>

After

Width:  |  Height:  |  Size: 432 B

12
profile/top-langs.svg Normal file
View File

@@ -0,0 +1,12 @@
<svg xmlns="http://www.w3.org/2000/svg" width="300" height="200" viewBox="0 0 300 200" fill="none">
<style>
text { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Helvetica', 'Arial', sans-serif; }
</style>
<rect width="300" height="200" fill="#141321" rx="4.5"/>
<text x="150" y="100" text-anchor="middle" fill="#fff" font-size="14">
Top languages card will be
</text>
<text x="150" y="120" text-anchor="middle" fill="#fff" font-size="14">
generated by workflow
</text>
</svg>

After

Width:  |  Height:  |  Size: 517 B