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

Re: git repack and dumb protocols

From
PHPeter Harris <git@peter.is-a-geek.org>
Date
Jun 4, 2009, 12:47 UTC
Message-ID
<eaa105840906040547o473801c8jca309c821282a091@mail.gmail.com>
In-Reply-To
<200906031950.56974.lists@informa.tiker.net>
On Wed, Jun 3, 2009 at 7:50 PM, Andreas Klöckner wrote:
Show 11 quoted lines
>
> 8< ----------------------------------------------------------------------
> Especially useful when packing a repository that is used for private
> development and there is no need to worry about people fetching via dumb
> protocols from it. 8<
> ----------------------------------------------------------------------
>
> It says this relating to the '-a' option, but it makes me wonder if I'll break
> copies of the repo that other people have pulled if I use 'repack'? What are
> the possible interactions and things to keep in mind between repack and dumb
> protocols?
It won't break any copies, but it may cause excessive network use.

Dumb protocols can only fetch or not-fetch the entire pack. So if someone hasn't fetched since the last push, the next time they do a "git pull", they will retrieve the entire repository. Even if they only need a single small commit.

As you can imagine, people using dumb protocols over slow connections may become somewhat annoyed with the admin that often does a repack -a.

You do want to repack (usually without -a -- but see also ".keep") periodically, though. Working out a schedule depends on the activity level of the repository, and is left as an exercise for the reader.

> In any case, I would like to suggest that the rather ominous-sounding text in
> the manpage be replaced with something more concrete, i.e. "If you repack an
> archive that has people fetching via dumb protocols from it, X, Y, and Z will
> happen."
Patches welcome.
Peter Harris
Previous: Michael J Gruber
Message 9 of 9 in “git repack and dumb protocols”
  1. Andreas KlöcknerJun 3, 2009
  2. git-pack.txt: Clarify implications of -a for dumb protocolsMichael J Gruber, Jun 4, 2009
  3. [PATCHv1+eps] git-repack.txt: Clarify implications of -a for dumb protocolsMichael J Gruber, Jun 4, 2009
  4. Andreas KlöcknerJun 4, 2009
  5. Stephen BoydJun 4, 2009
  6. Michael J GruberJun 5, 2009
  7. Stephen BoydJun 5, 2009
  8. git-repack.txt: Clarify implications of -a for dumb protocolsMichael J Gruber, Jun 9, 2009
  9. Peter HarrisJun 4, 2009

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.