Skip to content

Update README findings #21

Update README findings

Update README findings #21

Workflow file for this run

name: Update README findings
on:
schedule:
- cron: "0 12 * * 0"
workflow_dispatch:
permissions:
contents: read
jobs:
update-readme:
runs-on: ubuntu-latest
steps:
- name: Create GitHub App token
id: app-token
uses: actions/create-github-app-token@v1
with:
app-id: ${{ secrets.SOLVRO_APP_ID }}
private-key: ${{ secrets.SOLVRO_APP_PRIVATE_KEY }}
owner: Solvro
- name: Checkout repository
uses: actions/checkout@v4
with:
repository: Solvro/script-eslint-analyzer
token: ${{ steps.app-token.outputs.token }}
ref: main
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.14"
- name: Set up uv
uses: astral-sh/setup-uv@v5
- name: Install dependencies
run: uv sync
- name: Run analyzer
env:
GH_TOKEN: ${{ steps.app-token.outputs.token }}
run: |
uv run eslint-analyzer \
--org Solvro \
--root-dir "$RUNNER_TEMP/eslint-analyzer-repos" \
--output result.tsv \
--format tsv \
--summary-output summary.md
- name: Update README generated section
run: python scripts/update_readme.py --readme README.md --summary summary.md
- name: Commit and push README changes
env:
SOLVRO_APP_TOKEN: ${{ steps.app-token.outputs.token }}
run: |
git config user.name "${{ steps.app-token.outputs.app-slug }}[bot]"
git config user.email "${{ steps.app-token.outputs.app-slug }}[bot]@users.noreply.github.com"
if git diff --quiet -- README.md; then
echo "README findings are already up to date."
exit 0
fi
git add README.md
git commit -m "chore(readme): update ESLint analyzer findings"
git push "https://x-access-token:${SOLVRO_APP_TOKEN}@github.com/Solvro/script-eslint-analyzer.git" HEAD:main