Skip to content

[pre-commit.ci] pre-commit autoupdate #85

[pre-commit.ci] pre-commit autoupdate

[pre-commit.ci] pre-commit autoupdate #85

Workflow file for this run

---
name: gitlint
on:
push:
pull_request:
workflow_dispatch:
jobs:
checks:
runs-on: "ubuntu-latest"
if: >
github.event_name == 'pull_request' ||
(github.event.before != '0000000000000000000000000000000000000000' && !github.event.forced)
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup python
uses: actions/setup-python@v5
with:
python-version: '3.11'
- uses: actions/cache@v4
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip
- name: Install gitlint
run: pip install gitlint
- name: gitlint for PR
run: >
gitlint --debug
--commits ${{ github.event.pull_request.base.sha }}..${{ github.event.pull_request.head.sha }}
if: github.event_name == 'pull_request'
- name: gitlint for push event
run: gitlint --debug --commits ${{ github.event.before }}..${{ github.event.after }}
if: github.event_name == 'push'