Skip to content

Allow executing specific hook #281

@ruudk

Description

@ruudk

When you have multiple pre-commit hooks, you can only use vendor/bin/captainhook pre-commit to execute all of them.

But I want to only execute a single hook on CI.

Use case: My pre-commit hook runs phpstan, php-cs-fixer, phpunit and a custom CaptainHook PHP implementation.

On CI I run phpstan, php-cs-fixer and phpunit separately. But the custom CaptainHook PHP implementation I want to run.

Ideally, I can name them, and then use vendor/bin/captainhook pre-commit the-name.

Metadata

Metadata

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions