forked from AD7six/git-hooks
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathconfig.sample.php
57 lines (57 loc) · 1.18 KB
/
config.sample.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
<?php
/**
* The format for this array is:
* branchnamepattern
* git-hook
* script to run
* OR
* script to run => halt on error
*
* the branch name pattern is optional, if you want one set of hooks for all branches
* you can remove that level from the array.
*
* Anything else present in $config is ignored by the one-hook script, but can be
* picked up by the individual scripts
*/
$config = array(
'master' => array(),
'develop' => array(),
'feature/*' => array(),
'release/*' => array(),
'hotfix/*' => array(),
'support/*' => array(),
'*' => array(
'pre-commit' => array(
'php/lint.php' => true,
'js/lint.php' => true,
'php/phpcs.php',
'php/phpunit.php',
'images/optimize.php',
),
'post-commit' => array(
'misc/happy-commits',
),
'post-merge' => array(
'php/lint.php',
'js/lint.php'
),
'php' => array(
'lint' => array(
'pattern' => '/\.php$/'
),
'phpcs' => array(
'-n' => true,
'-s' => true,
'--extensions' => 'php,ctp',
'--encoding' => 'UTF-8',
'--standard' => 'Cake',
'--report-width' => trim(`tput cols`)
)
),
'js' => array(
'lint' => array(
'pattern' => '/\.js$/'
)
)
)
);