Re: Clone from shallow bundle bug

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

On 03/31/2015 06:17 PM, Junio C Hamano wrote:
> Phillip Susi <psusi@xxxxxxxxxx> writes:
> 
>> I made a shallow clone of my repo, then used git bundle create to
>> pack it all into a bundle file, then cloned from that bundle.
> 
> I think the introdution of shallow clone feature broke git bundle
> create by not teaching it that its shallow boundaries are
> prerequisite commits to unbundle its contents.  IOW, the bundle
> created from the shallow clone is broken, I would think.

It seems to me that it isn't exactly broken; it just needs to put
something in the bundle noting that it was built from a shallow clone,
and then when cloning from the shallow bundle, the new clone needs its
.git/shallow file.

In other words, the bundle contains all of the objects in the shallow
clone, so a new shallow clone can be correctly constructed from the
bundle, it's just that the new clone doesn't *know* it too is shallow
and things like git log and gitk need to stop following the history
chain when they reach the shallow point rather than complain that the
rest of the history is missing ( which is intentional ).

For that matter, if you do create a depth limited bundle from a non
shallow repository, then try to clone from it, the cloned repo should
automatically become shallow rather than complain about missing history.

In other words, any time you clone from a bundle, the clone process
should check if the full history is in the bundle, and if not,
automatically make the new repo shallow so as to avoid the error
messages about the missing history.



-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQEcBAEBCgAGBQJVG15kAAoJENRVrw2cjl5RnvgH/iMyN/1U2zg+ju/teVEQIMRL
prvC60S9/yLxSp6RmiXpN2xuGHMkn7i2y6XpM9RQdE6ETeGaIw7UaDan3r7BPTSD
+Q9DrAM0g17IGNxvmGPiJZP7j0t2e43oTA9KM8alf6icMU/mWJgQsbtc9QFVfVkd
jsYevK1GR6ysrAHBAV6GxKfNw5yw3N+kTf9s2rKXWIFaArD0rcKJZVxiygMlhVSa
hT4j3+n5f3n0WMDVxFzhwOaW+yrPiXF3gs1pKFX8GT5g1BtvOAEnyskSgA5nZsNB
G53ncyyefinaaBqCvPSbcTLXmWLV8QuLBExc13BWXiVUD2rRNQr7u1ihbxWKyvU=
=D90B
-----END PGP SIGNATURE-----
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]