Update Language Badges #2
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
name: Update Language Badges | |
on: | |
schedule: | |
- cron: '0 0 * * *' # Run daily at midnight | |
workflow_dispatch: # Allow manual trigger | |
jobs: | |
update-badges: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-python@v3 | |
with: | |
python-version: '3.x' | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install requests PyGithub | |
- name: Update language badges | |
run: python .github/scripts/update_badges.py | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: Commit changes | |
run: | | |
git config --local user.email "github-actions[bot]@users.noreply.github.com" | |
git config --local user.name "github-actions[bot]" | |
git add README.md | |
git commit -m "chore: update language badges" || exit 0 | |
git push |