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

Re: [PATCH v3 1/4] Documentation/git-bundle.txt: mention full backup example

From
KHKristoffer Haugsbakk <kristofferhaugsbakk@fastmail.com>
Date
Nov 16, 2024, 14:28 UTC
Message-ID
<31492b4b-e8fa-4598-a975-fef2ec861b80@app.fastmail.com>
In-Reply-To
<xmqqh68c3vr8.fsf@gitster.g>
On Tue, Nov 12, 2024, at 23:58, Junio C Hamano wrote:
Show 36 quoted lines
> "Kristoffer Haugsbakk" <kristofferhaugsbakk@fastmail.com> writes:
>
>> Maybe it’s possible but I kind of want to say “okay just pop your
>> stashes and make regular commits/branches”.
>
> That requires _more_ than recording the value of the ref for stash,
> as data for the Nth stash is recorded as the Nth reflog entry for
> that ref, and the reflog data is not what fetch/push/clone/bundle
> commands make available.
>
>> I’m not sure how to formulate that.  Seems clumsy:
>>
>>      refs are included in the bundle (also `refs/stash` but that
>>      particular one won't be included in e.g. a clone):
>>
>> Would it be too drastic to use a footnote?
>
> I am not sure what you want to refer to with "that particular one",
> but the value of refs/stash does get recorded, and making a mirror
> clone out of the resulting bundle does give refs/stash with the
> value of the refs/stash in the original repository where the bundle
> was taken from.  So refs/stash _does_ get included.  What is not
> included is the reflog data for that ref (or any other ref, for that
> matter).
>
> Because the ref value is transferred via fetch/push/clone/bundle but
> the reflog (i.e. past values of a ref) data is *not*, "git stash
> show stash@{4}" is not something you can recreate in the copy of a
> repository, whether you create the copy with "clone" or "bundle +
> clone".  The story is the same for other refs, and stash is not that
> special in this regard.  "git show master@{yesterday}" in a freshly
> created copy would give something entirely different from what you
> would get in the original repository you mirror-cloned or took a
> bundle from.
>
> You'd need "cp -r" for that.
Thanks.  I get it now.
I always forget that the stash uses the reflog.
Previous: Junio C HamanoNext: kristofferhaugsbakk@fastmail.com
Message 28 of 37 in “Documentation/git-bundle.txt: promote --all for full backup”
  1. 0/4 Documentation/git-bundle.txt: promote --all for full backupkristofferhaugsbakk@fastmail.com, Oct 20, 2024
  2. 1/4 Documentation/git-bundle.txt: mention --all in Synopsiskristofferhaugsbakk@fastmail.com, Oct 20, 2024
  3. Kristoffer HaugsbakkOct 20, 2024
  4. Taylor BlauOct 21, 2024
  5. 2/4 Documentation/git-bundle.txt: mention full backup examplekristofferhaugsbakk@fastmail.com, Oct 20, 2024
  6. Taylor BlauOct 21, 2024
  7. Kristoffer HaugsbakkOct 22, 2024
  8. 3/4 Documentation/git-bundle.txt: mention --all in spec. refskristofferhaugsbakk@fastmail.com, Oct 20, 2024
  9. Taylor BlauOct 21, 2024
  10. 4/4 Documentation/git-bundle.txt: discuss naïve backupskristofferhaugsbakk@fastmail.com, Oct 20, 2024
  11. Taylor BlauOct 21, 2024
  12. Taylor BlauOct 22, 2024
  13. Kristoffer HaugsbakkOct 22, 2024
  14. 0/3 Documentation/git-bundle.txt: promote --all for full backupkristofferhaugsbakk@fastmail.com, Oct 29, 2024
  15. 1/3 Documentation/git-bundle.txt: mention full backup examplekristofferhaugsbakk@fastmail.com, Oct 29, 2024
  16. Junio C HamanoNov 2, 2024
  17. Kristoffer HaugsbakkNov 6, 2024
  18. 2/3 Documentation/git-bundle.txt: mention --all in spec. refskristofferhaugsbakk@fastmail.com, Oct 29, 2024
  19. 3/3 Documentation/git-bundle.txt: discuss naïve backupskristofferhaugsbakk@fastmail.com, Oct 29, 2024
  20. Junio C HamanoNov 2, 2024
  21. Taylor BlauOct 29, 2024
  22. 0/4 Documentation/git-bundle.txt: promote --all for full backupkristofferhaugsbakk@fastmail.com, Nov 7, 2024
  23. 1/4 Documentation/git-bundle.txt: mention full backup examplekristofferhaugsbakk@fastmail.com, Nov 7, 2024
  24. Junio C HamanoNov 8, 2024
  25. Kristoffer HaugsbakkNov 10, 2024
  26. Kristoffer HaugsbakkNov 12, 2024
  27. Junio C HamanoNov 12, 2024
  28. Kristoffer HaugsbakkNov 16, 2024
  29. 2/4 Documentation/git-bundle.txt: remove old `--all` examplekristofferhaugsbakk@fastmail.com, Nov 7, 2024
  30. 3/4 Documentation/git-bundle.txt: mention --all in spec. refskristofferhaugsbakk@fastmail.com, Nov 7, 2024
  31. 4/4 Documentation/git-bundle.txt: discuss naïve backupskristofferhaugsbakk@fastmail.com, Nov 7, 2024
  32. Junio C HamanoNov 7, 2024
  33. 0/4 Documentation/git-bundle.txt: promote --all for full backupkristofferhaugsbakk@fastmail.com, Nov 16, 2024
  34. 1/4 Documentation/git-bundle.txt: mention full backup examplekristofferhaugsbakk@fastmail.com, Nov 16, 2024
  35. 2/4 Documentation/git-bundle.txt: remove old `--all` examplekristofferhaugsbakk@fastmail.com, Nov 16, 2024
  36. 3/4 Documentation/git-bundle.txt: mention --all in spec. refskristofferhaugsbakk@fastmail.com, Nov 16, 2024
  37. 4/4 Documentation/git-bundle.txt: discuss naïve backupskristofferhaugsbakk@fastmail.com, Nov 16, 2024

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.