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

Re: [PATCH v2 00/16] First class shallow clone

From
Philip Oakley <philipoakley@iee.org>
Date
Jul 22, 2013, 23:41 UTC
Message-ID
<79A9AB6FF00042D1B3E0D26B9855CCAB@PhilipOakley>
In-Reply-To
<1374314290-5976-1-git-send-email-pclouds@gmail.com>
From: "Nguyễn Thái Ngọc Duy" <pclouds@gmail.com>
Subject: [PATCH v2 00/16] First class shallow clone
It's nice to see that shallow can be a first class clone.

Thinking outside the box, does this infrastructure offer the opportunity to maybe add a date based depth option that would establish the shallow watermark based on date rather than count. (e.g. the "deepen" SP depth could have an alternate with a leading 'T' to indicate a time limit ratherv than revision count - I'm expecting such a format would be an error for existing servers).

My other thought was this style of cut limit list may also allow a big file limit to do a similar process of listing objects (e.g. blobs) that are size-shallow in the repo, though it maybe a long list on some repos, or with a small size limit.

Philip
Show 82 quoted lines
> v2 includes:
>
> - fix Junio comments, especially the one that may lead to incomplete
>   commit islands.
> - fix send-pack setting up temporary shallow file, but never passes
>   it to index-pack/unpack-objects (also fix the tests to catch this)
> - support smart http
> - add core.noshallow for repos that wish to be always complete
> - fix locally cloning a shallow repository
> - make upload-pack pass --shallow-file to pack-objects in order to
>   remove duplicate object counting code just for shallow case.
>
> Nguyễn Thái Ngọc Duy (16):
>  send-pack: forbid pushing from a shallow repository
>  {receive,upload}-pack: advertise shallow graft information
>  connect.c: teach get_remote_heads to parse "shallow" lines
>  Move setup_alternate_shallow and write_shallow_commits to shallow.c
>  fetch-pack: support fetching from a shallow repository
>  {send,receive}-pack: support pushing from a shallow clone
>  send-pack: support pushing to a shallow clone
>  upload-pack: let pack-objects do the object counting in shallow case
>  pack-protocol.txt: a bit about smart http
>  Add document for command arguments for supporting smart http
>  {fetch,upload}-pack: support fetching from a shallow clone via smart 
> http
>  receive-pack: support pushing to a shallow clone via http
>  send-pack: support pushing from a shallow clone via http
>  git-clone.txt: remove shallow clone limitations
>  config: add core.noshallow to prevent turning a repo into a shallow 
> one
>  clone: use git protocol for cloning shallow repo locally
>
> Documentation/config.txt                  |   5 +
> Documentation/git-clone.txt               |   7 +-
> Documentation/git-fetch-pack.txt          |  11 +-
> Documentation/git-receive-pack.txt        |  16 ++-
> Documentation/git-send-pack.txt           |   9 +-
> Documentation/git-upload-pack.txt         |  13 ++-
> Documentation/technical/pack-protocol.txt |  76 ++++++++++++-
> builtin/clone.c                           |  14 ++-
> builtin/fetch-pack.c                      |   6 +-
> builtin/receive-pack.c                    |  76 +++++++++++--
> builtin/send-pack.c                       |   7 +-
> cache.h                                   |   4 +-
> commit.h                                  |  27 +++++
> config.c                                  |   5 +
> connect.c                                 |  12 +-
> environment.c                             |   1 +
> fetch-pack.c                              |  90 ++++++---------
> fetch-pack.h                              |   1 +
> remote-curl.c                             |   4 +-
> send-pack.c                               |  57 +++++++++-
> send-pack.h                               |   4 +-
> shallow.c                                 | 147 
> +++++++++++++++++++++++++
> t/t5530-upload-pack-error.sh              |   3 -
> t/t5536-fetch-shallow.sh (new +x)         | 141 
> ++++++++++++++++++++++++
> t/t5537-push-shallow.sh (new +x)          | 176 
> ++++++++++++++++++++++++++++++
> t/t5601-clone.sh                          |   7 ++
> transport.c                               |  14 ++-
> upload-pack.c                             | 132 ++++++----------------
> 28 files changed, 858 insertions(+), 207 deletions(-)
> create mode 100755 t/t5536-fetch-shallow.sh
> create mode 100755 t/t5537-push-shallow.sh
>
> -- 
> 1.8.2.83.gc99314b
>
> --
> To unsubscribe from this list: send the line "unsubscribe git" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>
>
> -----
> No virus found in this message.
> Checked by AVG - www.avg.com
> Version: 2013.0.3349 / Virus Database: 3204/6504 - Release Date: 
> 07/19/13
> 
Previous: Nguyễn Thái Ngọc DuyNext: Duy Nguyen
Message 35 of 44 in “First class shallow clone”
  1. 0/7 First class shallow cloneNguyễn Thái Ngọc Duy, Jul 17, 2013
  2. 1/7 transport.h: remove send_pack prototype, already defined in send-pack.hNguyễn Thái Ngọc Duy, Jul 17, 2013
  3. 2/7 {receive,upload}-pack: advertise shallow graft informationNguyễn Thái Ngọc Duy, Jul 17, 2013
  4. 3/7 connect.c: teach get_remote_heads to parse "shallow" linesNguyễn Thái Ngọc Duy, Jul 17, 2013
  5. Junio C HamanoJul 20, 2013
  6. 4/7 Move setup_alternate_shallow and write_shallow_commits to shallow.cNguyễn Thái Ngọc Duy, Jul 17, 2013
  7. 5/7 fetch-pack: support fetching from a shallow repositoryNguyễn Thái Ngọc Duy, Jul 17, 2013
  8. Junio C HamanoJul 20, 2013
  9. 6/7 {send,receive}-pack: support pushing from a shallow cloneNguyễn Thái Ngọc Duy, Jul 17, 2013
  10. 7/7 send-pack: support pushing to a shallow cloneNguyễn Thái Ngọc Duy, Jul 17, 2013
  11. 00/16 First class shallow cloneNguyễn Thái Ngọc Duy, Jul 20, 2013
  12. 01/16 send-pack: forbid pushing from a shallow repositoryNguyễn Thái Ngọc Duy, Jul 20, 2013
  13. 02/16 {receive,upload}-pack: advertise shallow graft informationNguyễn Thái Ngọc Duy, Jul 20, 2013
  14. 03/16 connect.c: teach get_remote_heads to parse "shallow" linesNguyễn Thái Ngọc Duy, Jul 20, 2013
  15. 04/16 Move setup_alternate_shallow and write_shallow_commits to shallow.cNguyễn Thái Ngọc Duy, Jul 20, 2013
  16. 05/16 fetch-pack: support fetching from a shallow repositoryNguyễn Thái Ngọc Duy, Jul 20, 2013
  17. Philip OakleyJul 22, 2013
  18. Duy NguyenJul 23, 2013
  19. Duy NguyenJul 23, 2013
  20. 06/16 {send,receive}-pack: support pushing from a shallow cloneNguyễn Thái Ngọc Duy, Jul 20, 2013
  21. 07/16 send-pack: support pushing to a shallow cloneNguyễn Thái Ngọc Duy, Jul 20, 2013
  22. 08/16 upload-pack: let pack-objects do the object counting in shallow caseNguyễn Thái Ngọc Duy, Jul 20, 2013
  23. 09/16 pack-protocol.txt: a bit about smart httpNguyễn Thái Ngọc Duy, Jul 20, 2013
  24. 10/16 Add document for command arguments for supporting smart httpNguyễn Thái Ngọc Duy, Jul 20, 2013
  25. 11/16 {fetch,upload}-pack: support fetching from a shallow clone via smart httpNguyễn Thái Ngọc Duy, Jul 20, 2013
  26. 12/16 receive-pack: support pushing to a shallow clone via httpNguyễn Thái Ngọc Duy, Jul 20, 2013
  27. 13/16 send-pack: support pushing from a shallow clone via httpNguyễn Thái Ngọc Duy, Jul 20, 2013
  28. 14/16 git-clone.txt: remove shallow clone limitationsNguyễn Thái Ngọc Duy, Jul 20, 2013
  29. 15/16 config: add core.noshallow to prevent turning a repo into a shallow oneNguyễn Thái Ngọc Duy, Jul 20, 2013
  30. Philip OakleyJul 22, 2013
  31. Duy NguyenJul 23, 2013
  32. Junio C HamanoJul 23, 2013
  33. Philip OakleyJul 23, 2013
  34. 16/16 clone: use git protocol for cloning shallow repo locallyNguyễn Thái Ngọc Duy, Jul 20, 2013
  35. Philip OakleyJul 22, 2013
  36. Duy NguyenJul 23, 2013
  37. Junio C HamanoJul 23, 2013
  38. Duy NguyenJul 23, 2013
  39. Philip OakleyJul 23, 2013
  40. Duy NguyenJul 24, 2013
  41. Philip OakleyJul 24, 2013
  42. Piotr KrukowieckiJul 24, 2013
  43. Duy NguyenJul 24, 2013
  44. Piotr KrukowieckiJul 24, 2013

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.