aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.github/PULL_REQUEST_TEMPLATE.md2
-rwxr-xr-x.husky/pre-commit9
2 files changed, 8 insertions, 3 deletions
diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md
index 44de8e2e2..b2cd3a1eb 100644
--- a/.github/PULL_REQUEST_TEMPLATE.md
+++ b/.github/PULL_REQUEST_TEMPLATE.md
@@ -28,7 +28,7 @@
28#### Checklist 28#### Checklist
29<!-- Remove items that do not apply. For completed items, change [ ] to [x]. --> 29<!-- Remove items that do not apply. For completed items, change [ ] to [x]. -->
30- [ ] My pull request is properly named 30- [ ] My pull request is properly named
31- [ ] The changes respect the code style of the project (`$ npm run lint && npm run reformat-files && npm run manage-translations && npm run apply-branding`) 31- [ ] The changes respect the code style of the project (`npm run prepare-code`)
32- [ ] `npm test` passes 32- [ ] `npm test` passes
33- [ ] I tested/previewed my changes locally 33- [ ] I tested/previewed my changes locally
34 34
diff --git a/.husky/pre-commit b/.husky/pre-commit
index f1e7b9824..305fe1ebf 100755
--- a/.husky/pre-commit
+++ b/.husky/pre-commit
@@ -1,4 +1,9 @@
1#!/bin/sh 1#!/bin/sh
2. "$(dirname "$0")/_/husky.sh"
3 2
4npm run lint && npm run reformat-files && npm run manage-translations && npm run apply-branding 3FILE_NAME="$(dirname "$0")/_/husky.sh"
4
5# Conditionally invoke so as to avoid running npm commands if this is a clean checkout (ie before installing npm modules)
6if [ -f $FILE_NAME ]; then
7 . $FILE_NAME
8 npm run prepare-code
9fi