Skip to content

Update Language Stats #54

Update Language Stats

Update Language Stats #54

Workflow file for this run

name: Update Language Stats
on:
schedule:
- cron: "0 0 * * 1" # Every Monday
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Checkout target repo
uses: actions/checkout@v3
- name: Download self-reposcope binary from GitHub Release
shell: bash
run: |
curl -L https://github.com/4okimi7uki/self-reposcope/releases/latest/download/self-reposcope -o self-reposcope
chmod +x ./self-reposcope
- name: Run self-reposcope CLI
shell: bash
run: |
mkdir -p output
./self-reposcope --token ${{ secrets.REPOSCOPE_TOKEN }}
- name: Commit and Push updated SVGs
shell: bash
env:
GH_PAT: ${{ secrets.REPOSCOPE_TOKEN }}
run: |
git config --global user.name 'github-actions[bot]'
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
git add output/*.svg
if git diff --cached --quiet; then
echo "No changes to commit"
else
git commit -m "update: language stats svg"
git push https://x-access-token:${GH_PAT}@github.com/${{ github.repository }} HEAD:main
fi