git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH v2] builtin/init-db: handle bare clones when core.bare set to false

From
Junio C Hamano <gitster@pobox.com>
Date
Mar 10, 2021, 23:09 UTC
Message-ID
<xmqq7dmeip1v.fsf@gitster.g>
In-Reply-To
<20210310011120.1151749-1-sandals@crustytoothpaste.net>
"brian m. carlson" <sandals@crustytoothpaste.net> writes:
Show 11 quoted lines
> diff --git a/t/t5606-clone-options.sh b/t/t5606-clone-options.sh
> index 52e5789fb0..c2b71e78c5 100755
> --- a/t/t5606-clone-options.sh
> +++ b/t/t5606-clone-options.sh
> @@ -104,6 +104,14 @@ test_expect_success 'redirected clone -v does show progress' '
>  
>  '
>  
> +test_expect_success 'clone does not segfault with --bare and core.bare=false' '
> +	test_config_global core.bare false &&
> +	git clone --bare parent clone-bare &&

Because "git clone" does so many different things from the normal codepath in the "local" codepath, I'd prefer to see this one done with the "--no-local" option (or alternatively, we could test both, but that may be overkill).

Show 8 quoted lines
> +	echo true >expect &&
> +	git -C clone-bare rev-parse --is-bare-repository >actual &&
> +	test_cmp expect actual
> +'
> +
>  test_expect_success 'chooses correct default initial branch name' '
>  	GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME= \
>  	git -c init.defaultBranch=foo init --bare empty &&
Previous: brian m. carlsonNext: brian m. carlson
Message 9 of 10 in “bug: conflicting core.bare setting causes segfault during bare clone”
  1. Vusich, JosephMar 3, 2021
  2. brian m. carlsonMar 3, 2021
  3. Junio C HamanoMar 4, 2021
  4. Vusich, JosephMar 4, 2021
  5. builtin/init-db: handle bare clones when core.bare set to falsebrian m. carlson, Mar 8, 2021
  6. Eric SunshineMar 8, 2021
  7. brian m. carlsonMar 8, 2021
  8. builtin/init-db: handle bare clones when core.bare set to falsebrian m. carlson, Mar 10, 2021
  9. Junio C HamanoMar 10, 2021
  10. brian m. carlsonMar 10, 2021

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.