From fecc65b655fb3e60a6e8de221b0170f00065f9ab Mon Sep 17 00:00:00 2001 From: Oliver Davies Date: Thu, 23 Nov 2023 08:25:55 +0000 Subject: [PATCH] fix(git-hooks): Set `TTY` if using Docker --- CHANGELOG.md | 1 + templates/common/.githooks/pre-push.twig | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8aba875..c692ce0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,7 @@ * The `pre-push` Git hook should use `./run test:commit` instead of `just test-commit` since `just` is no longer used. * Recursively merge `build.defaults.yaml` into the given configuration. +* Set `TTY` in the `pre-push` Git hook so it can run if using Docker. ### Changed diff --git a/templates/common/.githooks/pre-push.twig b/templates/common/.githooks/pre-push.twig index dca4863..88389cf 100755 --- a/templates/common/.githooks/pre-push.twig +++ b/templates/common/.githooks/pre-push.twig @@ -4,4 +4,8 @@ set -o errexit +{% if isDocker %} +export TTY="-T" +{% endif %} + ./run test:commit