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

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Conventional Commit PR Title Validator

This GitHub Action validates Pull Request titles to ensure they follow the Conventional Commits specification. It uses the CCU (Conventional Commit Util) tool to enforce structured and compliant commit messages.

Configuration

The action can be customized using the following inputs:

Input Description Required Default
type Regular expression for commit type No build|chore|ci|docs|feat|fix|perf|refactor|revert|style|test
topic Regular expression for commit topic No (\([a-zA-Z0-9\-\.]+\))?(!)?
message Regular expression for commit message No .*
pr_title String to validate Yes

Example

name: Validate PR Title
on:
  pull_request:
    types: [opened, edited, synchronize, reopened]

jobs:
  validate:
    runs-on: ubuntu-latest
    steps:
      - name: Validate PR Title
        uses: lab42/ccu-action@main
        with:
          type: 'feat|fix|chore'
          pr_title: ${{ github.event.pull_request.title }}

Valid PR Title Examples

  • feat: add new feature
  • fix(auth): resolve login issue
  • docs: update README
  • chore(deps): update dependencies
  • feat!: breaking change in API

Contributing

I welcome contributions to this project! If you have ideas for new features or improvements, please submit a feature request or contribute directly to the project.

License

This project is licensed under the MIT License.

About

Conventional Commit Util Github Action

Resources

Stars

Watchers

Forks

Releases

Packages

Used by

Contributors