From 9acec235a6c47c3bede917187808a8acd1369050 Mon Sep 17 00:00:00 2001 From: "Rafael G. Martins" Date: Wed, 30 May 2018 22:19:59 +0200 Subject: git-receiver: allow users to change the base directory this is useful mostly for shared environments that just provide one shell user. --- tests/blogc-git-receiver/check_post_receive.sh.in | 2 +- tests/blogc-git-receiver/check_pre_receive.sh.in | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'tests/blogc-git-receiver') diff --git a/tests/blogc-git-receiver/check_post_receive.sh.in b/tests/blogc-git-receiver/check_post_receive.sh.in index 9c6ded1..f0dde80 100755 --- a/tests/blogc-git-receiver/check_post_receive.sh.in +++ b/tests/blogc-git-receiver/check_post_receive.sh.in @@ -110,7 +110,7 @@ mirror = ${TEMP}/repos/bar6.git mirror = lol EOF git init --bare "${TEMP}/repos/bar6.git" &> /dev/null -HOME="${TEMP}" ${TESTS_ENVIRONMENT} ./repos/foo.git/hooks/post-receive 2>&1 | tee "${TEMP}/output.txt" +BLOGC_GIT_RECEIVER_BASEDIR="${TEMP}" ${TESTS_ENVIRONMENT} ./repos/foo.git/hooks/post-receive 2>&1 | tee "${TEMP}/output.txt" grep "[new branch] *master" "${TEMP}/output.txt" &> /dev/null rm "${TEMP}/output.txt" diff --git a/tests/blogc-git-receiver/check_pre_receive.sh.in b/tests/blogc-git-receiver/check_pre_receive.sh.in index e9181eb..6021cfb 100755 --- a/tests/blogc-git-receiver/check_pre_receive.sh.in +++ b/tests/blogc-git-receiver/check_pre_receive.sh.in @@ -199,7 +199,7 @@ EOF 0000000000000000000000000000000000000000 $(git rev-parse HEAD) refs/heads/master EOF - SHELL="${SELF}" HOME="${TEMP}" PATH="@abs_top_builddir@:${PATH}" GIT_DIR=. ${TESTS_ENVIRONMENT} ./hooks/pre-receive < "${TEMP}/payload.txt" 2>&1 | tee "${TEMP}/output.txt" || true + SHELL="${SELF}" BLOGC_GIT_RECEIVER_BASEDIR="${TEMP}" PATH="@abs_top_builddir@:${PATH}" GIT_DIR=. ${TESTS_ENVIRONMENT} ./hooks/pre-receive < "${TEMP}/payload.txt" 2>&1 | tee "${TEMP}/output.txt" || true grep "blogc-make: error: settings: " "${TEMP}/output.txt" &> /dev/null fi -- cgit v1.2.3-18-g5258