Skip to content

Support lock generation in WORKSPACE #17

Support lock generation in WORKSPACE

Support lock generation in WORKSPACE #17

Workflow file for this run

name: Pre-commit checks
on:
pull_request:
jobs:
precommit:
name: Pre-commit checks
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Pre-commit cache
uses: actions/cache@v3
with:
path: ~/.cache/pre-commit
key: ${{ runner.os }}-precommit
- name: Set up Python 3.12
uses: actions/setup-python@v4
with:
python-version: "3.12"
- name: Run pre-commit
run: |
pip install pre-commit
git fetch origin $GITHUB_BASE_REF $GITHUB_HEAD_REF
pre-commit run --from-ref origin/$GITHUB_BASE_REF --to-ref origin/$GITHUB_HEAD_REF