aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRafael G. Martins <rafael@rafaelmartins.eng.br>2016-10-10 03:45:48 +0200
committerRafael G. Martins <rafael@rafaelmartins.eng.br>2016-10-10 03:45:48 +0200
commit193b079d278e3847fce304b88603bbce5025a3f4 (patch)
tree3b65efe86646ccd3a00973ad00946c86c70a33b8
parent84dbde7d04a04434721ec9d2965af6d946713e5d (diff)
downloadblogc-193b079d278e3847fce304b88603bbce5025a3f4.tar.gz
blogc-193b079d278e3847fce304b88603bbce5025a3f4.tar.bz2
blogc-193b079d278e3847fce304b88603bbce5025a3f4.zip
Revert "trying to fix tests on travis"
This reverts commit 84dbde7d04a04434721ec9d2965af6d946713e5d.
-rw-r--r--src/blogc-git-receiver/post-receive.c4
-rwxr-xr-xtests/blogc-git-receiver/check_post_receive.sh8
2 files changed, 6 insertions, 6 deletions
diff --git a/src/blogc-git-receiver/post-receive.c b/src/blogc-git-receiver/post-receive.c
index dc29fa3..79c51ac 100644
--- a/src/blogc-git-receiver/post-receive.c
+++ b/src/blogc-git-receiver/post-receive.c
@@ -52,8 +52,8 @@ bgr_post_receive_hook(int argc, char *argv[])
// the 'mirror' remote, just push to it.
// this will be removed at some point, but will be kept for compatibility
// with old setups.
- if ((0 == system("git config -f config --get remote.mirror.pushurl &> /dev/null")) ||
- (0 == system("git config -f config --get remote.mirror.url &> /dev/null")))
+ if ((0 == system("git config --local remote.mirror.pushurl &> /dev/null")) ||
+ (0 == system("git config --local remote.mirror.url &> /dev/null")))
{
mirror = bc_strdup("mirror");
goto push;
diff --git a/tests/blogc-git-receiver/check_post_receive.sh b/tests/blogc-git-receiver/check_post_receive.sh
index ca1d428..954787b 100755
--- a/tests/blogc-git-receiver/check_post_receive.sh
+++ b/tests/blogc-git-receiver/check_post_receive.sh
@@ -44,18 +44,18 @@ git init --bare "${TEMP}/repos/bar.git" &> /dev/null
HOME="${TEMP}" ${TESTS_ENVIRONMENT} ./hooks/post-receive 2>&1 | tee "${TEMP}/output.txt"
grep "warning: repository mirroring disabled" "${TEMP}/output.txt" &> /dev/null
-git config remote.mirror.pushurl "${TEMP}/repos/bar.git"
+git config --local remote.mirror.pushurl "${TEMP}/repos/bar.git"
HOME="${TEMP}" ${TESTS_ENVIRONMENT} ./hooks/post-receive 2>&1 | tee "${TEMP}/output.txt"
grep "[new branch] *master" "${TEMP}/output.txt" &> /dev/null
-git config --unset remote.mirror.pushurl
+git config --local --unset remote.mirror.pushurl
rm -rf "${TEMP}/repos/bar.git"
git init --bare "${TEMP}/repos/bar.git" &> /dev/null
-git config remote.mirror.url "${TEMP}/repos/bar.git"
+git config --local remote.mirror.url "${TEMP}/repos/bar.git"
HOME="${TEMP}" ${TESTS_ENVIRONMENT} ./hooks/post-receive 2>&1 | tee "${TEMP}/output.txt"
grep "[new branch] *master" "${TEMP}/output.txt" &> /dev/null
-git config --unset remote.mirror.url
+git config --local --unset remote.mirror.url
rm -rf "${TEMP}/repos/bar.git"
cat > "${TEMP}/blogc-git-receiver.ini" <<EOF
[repo:boo.git]