From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: David Kastrup Newsgroups: gmane.emacs.devel Subject: Re: Obscure error/warning/information message from git pull Date: Sun, 16 Nov 2014 10:33:34 +0100 Organization: Organization?!? Message-ID: <87bno7lcb5.fsf@fencepost.gnu.org> References: <20141114180521.GA3168@acm.acm> <20141114230235.GF3168@acm.acm> <87lhncoqrp.fsf@fencepost.gnu.org> <83389khn1g.fsf@gnu.org> <87h9y0omii.fsf@fencepost.gnu.org> <83vbmgg57x.fsf@gnu.org> <878ujcoj0k.fsf@fencepost.gnu.org> <20141115120506.GA3581@acm.acm> <87r3x4mszs.fsf@fencepost.gnu.org> <20141115195736.GB3378@acm.acm> <87mw7sur4y.fsf@Rainer.invalid> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: ger.gmane.org 1416130460 10328 80.91.229.3 (16 Nov 2014 09:34:20 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 16 Nov 2014 09:34:20 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Nov 16 10:34:13 2014 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1XpwDk-0001gc-VI for ged-emacs-devel@m.gmane.org; Sun, 16 Nov 2014 10:34:13 +0100 Original-Received: from localhost ([::1]:43297 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XpwDk-0007vT-Ja for ged-emacs-devel@m.gmane.org; Sun, 16 Nov 2014 04:34:12 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:56796) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XpwDT-0007vN-Ff for emacs-devel@gnu.org; Sun, 16 Nov 2014 04:34:01 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XpwDM-0002lR-8s for emacs-devel@gnu.org; Sun, 16 Nov 2014 04:33:55 -0500 Original-Received: from plane.gmane.org ([80.91.229.3]:34947) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XpwDM-0002lK-0K for emacs-devel@gnu.org; Sun, 16 Nov 2014 04:33:48 -0500 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1XpwDL-0001YB-4l for emacs-devel@gnu.org; Sun, 16 Nov 2014 10:33:47 +0100 Original-Received: from x2f516dd.dyn.telefonica.de ([2.245.22.221]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 16 Nov 2014 10:33:47 +0100 Original-Received: from dak by x2f516dd.dyn.telefonica.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 16 Nov 2014 10:33:47 +0100 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 59 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: x2f516dd.dyn.telefonica.de X-Face: 2FEFf>]>q>2iw=B6, xrUubRI>pR&Ml9=ao@P@i)L:\urd*t9M~y1^:+Y]'C0~{mAl`oQuAl \!3KEIp?*w`|bL5qr,H)LFO6Q=qx~iH4DN; i"; /yuIsqbLLCh/!U#X[S~(5eZ41to5f%E@'ELIi$t^ Vc\LWP@J5p^rst0+('>Er0=^1{]M9!p?&:\z]|;&=NP3AhB!B_bi^]Pfkw User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) Cancel-Lock: sha1:8YEHm3q7rdS+7/K8vSr/LAHtyEA= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 80.91.229.3 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:177290 Archived-At: Achim Gratz writes: > Alan Mackenzie writes: >> After a "git clone", the copy is not the same as the original. > > If you really want an exact copy of your local repository, then just > make a plain copy or do a mirror clone, THis implies making it "bare" > (without a work tree), so you'd then have to move things around so that > you can have your work tree checked out. But you can do that, it's just > that this is almost never what you want. > >> In particular, branches are not preserved. I don't know, as yet, what else >> fails to be copied, but I have no great confidence in the documentation >> to tell me. > > You don't want second generation clone of the Savannah repository, you > want another first generation one. Again, the most efficient way to do > this is to reference your already existing clone when doing it so that > the actual objects are not transferred again over the net, but taken > from the "master" clone. > > […] >> This is confusing. Is it the case that branches labelled >> "remotes/origin/..." are completely contained within the same repository? > > No, they are labels pointing to the (heads of the) corresponding > branches in the upstream repository. Git fetches all information sitting behind such labels whenever it fetches a label, so that "No" is either used in some extremely misleading manner or just mistaken. _Every_ branch in Git, remote-tracking or local, is just a label pointing to some object. Both upstream repository and local repository are object stores, and any object having the same SHA1 is the _same_ object. There is no such thing as "corresponding branch in the upstream repository". Object ids mean exactly the same in upstream and clones. It is one namespace. I can manually set a label without getting the information, local or remote. Then the repository is incomplete (git fsck would complain). I can fill in the missing objects in any way I like: by fetching them, or by using git hash-object -w on a file with suitable content. > A branch is nothing more than a label in Git, all you really need to > know is the SHA1 for the branch head to (re-)create it. Not really: you need the objects behind it as well. When deleting a branch, the object store of Git keeps them around for a few weeks and will clean them out then on the next garbage collection. If you recreate the branch head any time before that, this will work without problem. If you recreate it afterwards, the repository will be incomplete. Fetching branches is more reliable than creating references and hoping that the objects will happen to be around. -- David Kastrup