git fetch origin $SHA1 doesn't work as often as it could
- From
- JP 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