carterjones/infrastructure

View on GitHub
.github/workflows/pre-commit-update.yml

Summary

Maintainability
Test Coverage
name: pre-commit auto-update

on:
  schedule:
    - cron: '0 0 * * *'

jobs:
  auto-update:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - name: install python
        uses: actions/setup-python@v5.1.0
        with:
          python-version: 3.x
      - name: install pre-commit
        run: pip install pre-commit
      - name: run pre-commit autoupdate
        run: pre-commit autoupdate
      - name: create pull request
        uses: peter-evans/create-pull-request@v6
        with:
          branch: update/pre-commit-autoupdate
          title: update pre-commit hooks
          commit-message: update pre-commit hooks
          body: update pre-commit hooks
          labels: dependencies