From: Junio C Hamano Date: Thu, 03 May 2007 06:13:01 GMT Subject: Re: [PATCH 4/5] Add --remote option to send-pack Message-ID: <7vejly305u.fsf@assigned-by-dhcp.cox.net> In-Reply-To: Daniel Barkalow writes: > Indeed. Is there documentation on all the possibilities for refspecs > somewhere all together? I could only find it for particular programs, and > didn't see a no-colon option permitted anywhere. Documentation/pull-fetch-param.txt which is included by various manpages would be the best place to start. :: The canonical format of a parameter is `+?:`; that is, an optional plus `+`, followed by the source ref, followed by a colon `:`, followed by the destination ref. + The remote ref that matches is fetched, and if is not empty string, the local ref that matches it is fast forwarded using . Again, if the optional plus `+` is used, the local ref is updated even if it does not result in a fast forward update. Hmph. So could be empty, and in such a case there is no tracking. But this does not say missing colon is allowed (but that was intentionally left out as we clarify it later). Let's read on. After a few [Notes], we find this. Some short-cut notations are also supported. + * `tag ` means the same as `refs/tags/:refs/tags/`; it requests fetching everything up to the given tag. * A parameter without a colon is equivalent to : when pulling/fetching, so it merges into the current branch without storing the remote branch anywhere locally Ahh, so a refspec that does not have a colon, and ends with a colon (hence an empty ) are equivalent, and does not result in remote tracking.