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

git fetch origin $SHA1 doesn't work as often as it could

From
JSJP Sugarbroad <jpsugar@google.com>
Date
May 18, 2016, 20:20 UTC
Message-ID
<CAD0oC4yQzvAH=6a6Xgy6xOPoYCaO2zsDg5mDySkb6VJ6FdeeEQ@mail.gmail.com>

So I'm trying to make cloning the rust repo a little easier, and I noticed there's a new feature to `git submodule update --depth=1` -- but it doesn't work for this, even though it could.

Reason is that fetch-pack will only fetch by sha1 if the remote specifies allow_tip/unreachable_sha1, even if the sha1 specified matches an advertised ref.

My thought is to rework filter_refs() to match on oid if matching on name fails. Thoughts?

- JP
Next: Junio C Hamano
Message 1 of 4 in “git fetch origin $SHA1 doesn't work as often as it could”
  1. JP SugarbroadMay 18, 2016
  2. Junio C HamanoMay 18, 2016
  3. JP SugarbroadMay 18, 2016
  4. Jeff KingMay 19, 2016

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.