ccinn/husky-php
最新稳定版本:v0.4.2
Composer 安装命令:
composer require ccinn/husky-php
包简介
Similar to js-husky client git hook implementation
README 文档
README
PHP is combined with composer to implement functionality similar to js's NPM module husky
Git hooks made easy
Husky can prevent bad git commit, git push and more git's hooks
Code Contributors
This project exists thanks to all the people who contribute. [Contribute].
Branch
- v5.6-7.3.x => "ccinn/husky-php": "^0.1.0"
- v7.4 => "ccinn/husky-php": "^0.2.0"
- v8.0.0 => "ccinn/husky-php": "^0.4.0"
Install
In composer.json
"require-dev": {
"ccinn/composer-husky-plugin": "^0.1.0",
"ccinn/husky-php": "^0.4.0"
},
Or
In Shell
composer require --dev ccinn/composer-husky-plugin ccinn/husky-php
Docker
docker build --build-arg PHP_VERION=8.0.9 -t husky-php .
Usage
you can also configure hooks using .huskyrc or .huskyrc.json file.
// .huskyrc or .huskyrc.json { "hooks": { "pre-commit": "echo 'husky-php-pre-commit'", "pre-push": "echo 'husky-php-pre-push'", "...": "..." } }
Running the git action hooks will be triggered
git commit -m 'Keep calm and commit'
You will see
husky-php-pre-commit
Default
By default, the pre - commit
Default support features:
-
Detect code conflicts
-
Test code specifications
-
Check code syntax
Window User
You need run in bash environment, for example:GitBash
统计信息
- 总下载量: 26.52k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 69
- 点击次数: 1
- 依赖项目数: 1
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2019-05-09