config: only read .git/config from configured repos
[gitweb.git] / t / t1301-shared-repo.sh
index ac108754088d34758a75f14943516c4a701f0ca8..7c28642f2e76046f25a36722e12fe87a5e4cea06 100755 (executable)
@@ -172,4 +172,13 @@ test_expect_success POSIXPERM 'forced modes' '
        }" actual)"
 '
 
+test_expect_success POSIXPERM 'remote init does not use config from cwd' '
+       git config core.sharedrepository 0666 &&
+       umask 0022 &&
+       git init --bare child.git &&
+       echo "-rw-r--r--" >expect &&
+       modebits child.git/config >actual &&
+       test_cmp expect actual
+'
+
 test_done