summaryrefslogtreecommitdiffstats
path: root/.github/workflows/fixup.yml
blob: b9e392078919e0286f0eb2d06929dd898be91209 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
# This workflow is provided via the organization template repository
#
# https://github.com/nextcloud/.github
# https://docs.github.com/en/actions/learn-github-actions/sharing-workflows-with-your-organization

name: Pull request checks

on:
  pull_request:
    types: [opened, ready_for_review, reopened]

permissions:
  contents: read

concurrency:
  group: fixup-${{ github.head_ref || github.run_id }}
  cancel-in-progress: true

jobs:
  commit-message-check:
    if: github.event.pull_request.draft == false

    permissions:
      pull-requests: write
    name: Block fixup and squash commits

    runs-on: ubuntu-latest

    steps:
      - name: Run check
        uses: xt0rted/block-autosquash-commits-action@79880c36b4811fe549cfffe20233df88876024e7 # v2
        with:
          repo-token: ${{ secrets.GITHUB_TOKEN }}