-
Notifications
You must be signed in to change notification settings - Fork 2
FailInstruction element
Markus Hastreiter edited this page Mar 23, 2019
·
1 revision
The <FailInstruction> element writes a message specified with the Message attribute to the error output and notifies RepoCop to return an exit code other than 0 (thus notifying the caller - if used as pre-commit hook - to fail the commit). If used during a pre-commit hook this text will be shown to the committing user thus presenting information about why the commit failed.
| Attribute name | Status | Description |
|---|---|---|
| Message | mandatory | A text that will be send to error output and (if supported by the repository) shown to the commiting user. Use this message to state a reason why the commit failed. |
<FailInstruction Message="The path /branches/version_1.1 is locked and may no longer be modified.">
<ChangedPathCondition ChangedPathRegExPattern=".**/branches/version_1\.1.**" />
</FailInstruction>