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

Re: [PATCH v3 0/2] Add new "describe" atom

From
Kousik Sanagavarapu <five231003@gmail.com>
Date
Jul 21, 2023, 04:17 UTC
Message-ID
<ZLoG6a7tG-HisBhq@five231003>
In-Reply-To
<xmqqjzuu18oe.fsf@gitster.g>
On Thu, Jul 20, 2023 at 04:10:09PM -0700, Junio C Hamano wrote:
Show 26 quoted lines
> Junio C Hamano <gitster@pobox.com> writes:
> 
> > The linux-gcc job is where we force the initial branch name to be
> > 'main' and not 'master', so if your tests assume that the initial &
> > primary branch name is 'master', that may be something you need to
> > fix.
> 
> Perhaps something along the line of the attached patch?
> 
> The primary test repository t6300 uses is aware of the "problem"
> where the tester may set GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
> to 'main' and hacks it around by using
> 
> 	git branch -M main
> 
> as one of the first things it does, to _force_ the primary branch
> name always to 'main', whether the tester's environment forces "git"
> to start with 'main' or 'master', and existing tests in the script
> relies on 'main' being the primary branch.
> 
> But your tests are done in a repository newly created with your own
> "git init", so depending on the tester's environment, the primary
> branch may be 'master' or 'main'.  The way your new tests are
> written, however, things will fail if "refs/heads/master" is not the
> primary branch.
> 

I see. I looked at the trash directory by doing -v -i -d when running these describe tests and was under the impression that it is always master.I guess I should have had a bigger view of things.

Show 15 quoted lines
>  t/t6300-for-each-ref.sh | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git c/t/t6300-for-each-ref.sh w/t/t6300-for-each-ref.sh
> index 4bbba76874..489f4d9186 100755
> --- c/t/t6300-for-each-ref.sh
> +++ w/t/t6300-for-each-ref.sh
> @@ -563,7 +563,7 @@ test_expect_success 'color.ui=always does not override tty check' '
>  '
>  
>  test_expect_success 'setup for describe atom tests' '
> -	git init describe-repo &&
> +	git init -b master describe-repo &&
>  	(
>  		cd describe-repo &&
I'll add this to the re-rolled version.
Thanks
Previous: Junio C HamanoNext: Kousik Sanagavarapu
Message 26 of 38 in “Add new "describe" atom”
  1. 0/2 Add new "describe" atomKousik Sanagavarapu, Jul 5, 2023
  2. 1/2 ref-filter: add new "describe" atomKousik Sanagavarapu, Jul 5, 2023
  3. Junio C HamanoJul 6, 2023
  4. Kousik SanagavarapuJul 9, 2023
  5. 2/2 t6300: run describe atom tests on a different repoKousik Sanagavarapu, Jul 5, 2023
  6. 0/3 Add new "describe" atomKousik Sanagavarapu, Jul 14, 2023
  7. 1/3 ref filter: add multiple-option parsing functionsKousik Sanagavarapu, Jul 14, 2023
  8. 2/3 ref-filter: add new "describe" atomKousik Sanagavarapu, Jul 14, 2023
  9. Junio C HamanoJul 14, 2023
  10. Kousik SanagavarapuJul 15, 2023
  11. Junio C HamanoJul 15, 2023
  12. 3/3 t6300: run describe atom tests on a different repoKousik Sanagavarapu, Jul 14, 2023
  13. 0/2 Add new "describe" atomKousik Sanagavarapu, Jul 19, 2023
  14. 1/2 ref-filter: add multiple-option parsing functionsKousik Sanagavarapu, Jul 19, 2023
  15. Junio C HamanoJul 19, 2023
  16. Junio C HamanoJul 20, 2023
  17. Kousik SanagavarapuJul 20, 2023
  18. Junio C HamanoJul 20, 2023
  19. Glen ChooJul 20, 2023
  20. Junio C HamanoJul 20, 2023
  21. Glen ChooJul 21, 2023
  22. 2/2 ref-filter: add new "describe" atomKousik Sanagavarapu, Jul 19, 2023
  23. Junio C HamanoJul 19, 2023
  24. Junio C HamanoJul 20, 2023
  25. Junio C HamanoJul 20, 2023
  26. Kousik SanagavarapuJul 21, 2023
  27. 0/2 Add new "describe" atomKousik Sanagavarapu, Jul 23, 2023
  28. 1/2 ref-filter: add multiple-option parsing functionsKousik Sanagavarapu, Jul 23, 2023
  29. Junio C HamanoJul 24, 2023
  30. Kousik SanagavarapuJul 24, 2023
  31. Junio C HamanoJul 24, 2023
  32. Junio C HamanoJul 25, 2023
  33. 2/2 ref-filter: add new "describe" atomKousik Sanagavarapu, Jul 23, 2023
  34. Junio C HamanoJul 24, 2023
  35. 0/2 Add new "describe" atomKousik Sanagavarapu, Jul 25, 2023
  36. 1/2 ref-filter: add multiple-option parsing functionsKousik Sanagavarapu, Jul 25, 2023
  37. 2/2 ref-filter: add new "describe" atomKousik Sanagavarapu, Jul 25, 2023
  38. Junio C HamanoJul 25, 2023

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.