Re: How to stop sharing objects between repositories

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

 



Johannes Schindelin wrote:
Hmm.  I really would like a documentation patch, then.

As another way to do it, I've used something along the lines from
   http://article.gmane.org/gmane.comp.version-control.git/62062
namely:

<script>
gitdir=$(git rev-parse --git-dir)
[ -n "$gitdir" ] || die "cannot find Git directory"

cd "$gitdir"
a=objects/info/alternates
if [ -f $a ]; then
 git rev-parse --all HEAD | git pack-objects --revs objects/pack/pack
 rm $a
fi
</script>

I was not sure HEAD would be included via --all (e.g. HEAD pointing to a dangling commit), so I added it explicitly.

The reverse operation (enabling sharing for a standalone repository) is described here http://git.or.cz/gitwiki/GitFaq#Howtoshareobjectsbetweenexistingrepositories.3F

--
Daniel

--
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]