Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

A Github Action to prevent merging pull requests containing autosquash commit messages.

License

NotificationsYou must be signed in to change notification settings

xt0rted/block-autosquash-commits-action

Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace

Repository files navigation

CICodeQL

A Github Action to prevent merging pull requests containingautosquash commit messages.

How it works

If any commit message in the pull request starts withfixup! orsquash! the check status will be set toerror.

⚠️ GitHub's API only returns the first 250 commits of a PR so if you're working on a really large PR your fixup commits might not be detected.

Usage

on:pull_requestname:Pull Requestsjobs:message-check:name:Block Autosquash Commitsruns-on:ubuntu-lateststeps:      -name:Block Autosquash Commitsuses:xt0rted/block-autosquash-commits-action@v2with:repo-token:${{ secrets.GITHUB_TOKEN }}

You'll also need to add arequired status check rule for your action to block merging if it detects anyfixup! orsquash! commits.

Control Permissions

If your repository is usingcontrol permissions you'll need to setpull-request: read on either the workflow or the job.

Workflow Config

on:pull_requestname:Pull Requestpermissions:pull-requests:readjobs:message-check:name:Block Autosquash Commitsruns-on:ubuntu-lateststeps:      -name:Block Autosquash Commitsuses:xt0rted/block-autosquash-commits-action@v2with:repo-token:${{ secrets.GITHUB_TOKEN }}

Job Config

on:pull_requestname:Pull Requestjobs:message-check:name:Block Autosquash Commitsruns-on:ubuntu-latestpermissions:pull-requests:readsteps:      -name:Block Autosquash Commitsuses:xt0rted/block-autosquash-commits-action@v2with:repo-token:${{ secrets.GITHUB_TOKEN }}

About

A Github Action to prevent merging pull requests containing autosquash commit messages.

Topics

Resources

License

Stars

Watchers

Forks

Sponsor this project

 

Contributors3

  •  
  •  
  •  

[8]ページ先頭

©2009-2025 Movatter.jp