From 8353fc501538181a0bbcecd06fc0cfb6fa648250 Mon Sep 17 00:00:00 2001 From: Mark Tyers Date: Wed, 14 Nov 2018 09:38:41 +0000 Subject: [PATCH] added not on sharing hooks --- 04 Lab 1 Software Quality.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/04 Lab 1 Software Quality.md b/04 Lab 1 Software Quality.md index 5141de6..ac007cc 100644 --- a/04 Lab 1 Software Quality.md +++ b/04 Lab 1 Software Quality.md @@ -86,3 +86,11 @@ This week you are starting the development process. You are advised to use the ` 13. Modify the `pre-push` hook to run the jest test suite with code coverage. At this stage you can start building your system. Each time you commit code the linter will run. Each time you push your code it will run the unit tests. + +## Sharing Git Hooks + +By default the hooks directory contents are not part of the remote repository. T osolve this problem the following is recommended: + +1. Create a `.githooks` directory in the root of your project. +2. Create your hooks in this directory (make sure they are executable). +3. Create a shell script to copy the contents of the `.githooks` directory into the `.git/hooks` directory.