@@ -57,6 +57,7 @@ |
||
57 | 57 | * Associate a status with this message. |
58 | 58 | * |
59 | 59 | * @param Status $status |
60 | + * @return void |
|
60 | 61 | */ |
61 | 62 | public function addStatus(Status $status); |
62 | 63 |
@@ -13,6 +13,7 @@ |
||
13 | 13 | * Test a message against a number of validators. |
14 | 14 | * |
15 | 15 | * @param Message $message |
16 | + * @return void |
|
16 | 17 | */ |
17 | 18 | public function validate(Message $message); |
18 | 19 | } |
@@ -15,6 +15,7 @@ |
||
15 | 15 | * Check if a message passes a specific test, and return a status that identifies if it is or isn't. |
16 | 16 | * |
17 | 17 | * @param Message $message |
18 | + * @return void |
|
18 | 19 | */ |
19 | 20 | public function validate(Message $message); |
20 | 21 | } |
@@ -82,7 +82,7 @@ |
||
82 | 82 | if (file_exists($hookFile)) { |
83 | 83 | $existingHookFile = copy( |
84 | 84 | $hookFile, |
85 | - $hookFile.self::BACKUP_EXTENSION |
|
85 | + $hookFile . self::BACKUP_EXTENSION |
|
86 | 86 | ); |
87 | 87 | } |
88 | 88 |
@@ -34,7 +34,7 @@ discard block |
||
34 | 34 | #!/bin/sh |
35 | 35 | |
36 | 36 | vendor/bin/git-lint-validators git-lint-validator:hook $1 |
37 | -CONTENT; |
|
37 | +content; |
|
38 | 38 | |
39 | 39 | const TEMPLATE_CONTENTS = <<<'CONTENT' |
40 | 40 | Subject line |
@@ -48,7 +48,7 @@ discard block |
||
48 | 48 | # - Use the subject body to explain what and why vs. how |
49 | 49 | # - Wrap the subject body at 72 characters |
50 | 50 | |
51 | -CONTENT; |
|
51 | +content; |
|
52 | 52 | |
53 | 53 | /** |
54 | 54 | * Installs and activates the Git commit message |
@@ -110,7 +110,7 @@ discard block |
||
110 | 110 | } |
111 | 111 | } |
112 | 112 | |
113 | - $safeCommitMessage = preg_replace('/'.preg_quote($commentCharacter).'.*/', '', $commitMessage); |
|
113 | + $safeCommitMessage = preg_replace('/' . preg_quote($commentCharacter) . '.*/', '', $commitMessage); |
|
114 | 114 | $message = new MessageImplementation($safeCommitMessage); |
115 | 115 | |
116 | 116 | $validators->validate($message); |
@@ -124,7 +124,7 @@ discard block |
||
124 | 124 | |
125 | 125 | /** @var Status $status */ |
126 | 126 | foreach ($message->getStatuses() as $status) { |
127 | - $statusList[] = $status->getMessage().' ('.$status->getDetailsUrl().')'; |
|
127 | + $statusList[] = $status->getMessage() . ' (' . $status->getDetailsUrl() . ')'; |
|
128 | 128 | |
129 | 129 | $isPositive = $status->isPositive() && $isPositive; |
130 | 130 | } |