Update svgl badge data and readme #1176
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 svgl badge data and readme | |
on: | |
schedule: | |
- cron: "0 */6 * * *" | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: macos-14 | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: "3.10" | |
- name: Install dependencies | |
run: | | |
pip install aiohttp | |
- name: Run update script and generate readme | |
run: | | |
python lib/updateSvglBadge.py | |
- name: Configure git | |
run: | | |
git config --global user.name "${{ vars.GITUSERNAME }}" | |
git config --global user.email "${{ vars.GITUSEREMAIL }}" | |
- name: Commit and push changes | |
run: | | |
if git diff-index --quiet HEAD --; then | |
echo "No changes detected." | |
else | |
git add . | |
git commit -m "chore: update svgls" | |
fi | |
continue-on-error: true | |
- name: Push changes | |
uses: ad-m/github-push-action@master | |
with: | |
branch: main | |
github_token: ${{ secrets.GITHUB_TOKEN }} |