diff options
author | Diana Stanley <dstanley@gitlab.com> | 2019-03-07 14:43:14 -0800 |
---|---|---|
committer | Diana Stanley <dstanley@gitlab.com> | 2019-03-07 14:43:14 -0800 |
commit | 7aede9dc076bdf76be50103af64ea64283b155d0 (patch) | |
tree | d2af75b20314cafbe800b9ab454ec80b48649805 | |
parent | 1de36fd2eef900a93606e1c0558f736ad88717cd (diff) | |
download | gitlab-ce-20972-add-a-note-to-custom-hooks-docs.tar.gz |
Custom hooks should not rely on external libraries20972-add-a-note-to-custom-hooks-docs
-rw-r--r-- | doc/administration/custom_hooks.md | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/doc/administration/custom_hooks.md b/doc/administration/custom_hooks.md index 60ad4bf4e8f..09e866f7fae 100644 --- a/doc/administration/custom_hooks.md +++ b/doc/administration/custom_hooks.md @@ -14,6 +14,13 @@ See [Git SCM Server-Side Hooks][hooks] for more information about each hook type As of gitlab-shell version 2.2.0 (which requires GitLab 7.5+), GitLab administrators can add custom git hooks to any GitLab project. +When writing custom hooks, keep in mind that hooks that require specific runtime +environments may not work when committing files using the GitLab web UI. For +example, you may want a hook to lint files using the puppet binary. The puppet +binary calls out to the puppet gem, which is not included in the GitLab gemfile, +so this hook would fail when a commit comes through the GitLab web UI. Custom hooks +work best when they do not rely on external libraries. + ## Setup Normally, Git hooks are placed in the repository or project's `hooks` directory. |