Skip to content

CI: Add workflow to enforce rebase before merge #3

CI: Add workflow to enforce rebase before merge

CI: Add workflow to enforce rebase before merge #3

Workflow file for this run

name: Force rebased
on: [pull_request]
jobs:
force-rebase:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Is Rebased on master?
run: |
git checkout ${{ github.event.pull_request.head.ref }} \
merges="\$(git log --oneline ${{ github.event.pull_request.base.ref }}...HEAD --merges )"; \
echo "--- Merges ---\\n\${merges}"; [ -z "\${merges}" ]