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

Re: [PATCH/RFC 0/9] Pseudorefs

From
Michael Haggerty <mhagger@alum.mit.edu>
Date
Aug 2, 2015, 22:48 UTC
Message-ID
<55BE9E25.6050902@alum.mit.edu>
In-Reply-To
<1437713129-19373-1-git-send-email-dturner@twopensource.com>
On 07/24/2015 06:45 AM, David Turner wrote:
Show 15 quoted lines
> This series is another chunk of the pluggable refs backend work.  The
> major reason it is listed as "PATCH/RFC" is beacuse it breaks
> t9300-fast-import.sh, because fast-import wants to create a ref called
> TEMP_TAG, which would now be a pseudoref.  The commit that introduces
> this test says that cvs2svn creates a tag called TAG_FIXUP "as a branch
> name for temporary work needed to cleanup the tree prior to creating
> an annotated tag object."
> 
> It appears that cvs2svn still does this.  So I'm not quite sure what to
> do about this particular case.
> 
> As we discussed earlier, the motivation for this series is that refs
> backends other than the files-based backend need to treat per-worktree
> refs (HEAD) and pseudorefs (FETCH_HEAD) differently from other refs;
> other refs are per-repo rather than per-worktree.
Sorry, I missed this email while on vacation.

cvs2git needs to create a temporary reference for cobbling together tagged commits. Originally I was going to use the name `TAG_FIXUP`, as suggested by git-fast-import(1) [1]. But that functionality turned out to be buggy in `git fast-import` at the time. So I reported the bug but changed cvs2git to use `refs/heads/TAG.FIXUP` [2]. The bug in `git fast-import` was fixed, including the test case that you found, but I never changed cvs2git back to using the originally-planned name. The fact that the test case uses a name different than `TAG_FIXUP` probably means that Shawn thought that any references named similarly should be allowed.

Summary: support for a reference named `TAG_FIXUP` is not needed by
cvs2git. However, its use is a documented recommendation of `git
fast-import`, so it is quite possible that other importers are using
this name.

I expect that such importers would slightly prefer that this reference be worktree-specific, but I doubt that anybody really cares that much. It seems unlikely that people will run `git fast-import` in multiple worktrees simultaneously.

Michael

[1] http://git-scm.com/docs/git-fast-import#_use_tag_fixup_branches [2] https://github.com/mhagger/cvs2svn/blob/master/cvs2svn_lib/git_output_option.py#L502-L509

-- 
Michael Haggerty
mhagger@alum.mit.edu
Previous: David Turner
Message 20 of 20 in “Pseudorefs”
  1. 0/9 PseudorefsDavid Turner, Jul 24, 2015
  2. 1/9 refs: Introduce pseudoref and per-worktree ref conceptsDavid Turner, Jul 24, 2015
  3. Eric SunshineJul 24, 2015
  4. Junio C HamanoJul 24, 2015
  5. David TurnerJul 24, 2015
  6. Junio C HamanoJul 24, 2015
  7. Philip OakleyJul 24, 2015
  8. David TurnerJul 24, 2015
  9. 2/9 notes: replace pseudorefs with real refsDavid Turner, Jul 24, 2015
  10. 3/9 bisect: do not use update-ref for BISECT_HEADDavid Turner, Jul 24, 2015
  11. 4/9 tests: treat FETCH_HEAD as a pseudorefDavid Turner, Jul 24, 2015
  12. 5/9 tests: use --create-reflog option to git update-refDavid Turner, Jul 24, 2015
  13. 6/9 pseudorefs: create and use pseudoref update and delete functionsDavid Turner, Jul 24, 2015
  14. Junio C HamanoJul 24, 2015
  15. David TurnerJul 24, 2015
  16. Junio C HamanoJul 24, 2015
  17. 7/9 am/rebase: update pseudorefs by writing filesDavid Turner, Jul 24, 2015
  18. 8/9 rebase: use write_pseudorefDavid Turner, Jul 24, 2015
  19. 9/9 refs: forbid pseudoref updates through ref update APIDavid Turner, Jul 24, 2015
  20. Michael HaggertyAug 2, 2015

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.