From: Nguyen Thai Ngoc Duy Date: Mon, 17 Sep 2012 12:11:11 GMT Subject: Re: [PATCHv4] clone --single: limit the fetch refspec to fetched branch Message-ID: In-Reply-To: On Mon, Sep 17, 2012 at 7:06 PM, Nguyen Thai Ngoc Duy wrote: > --mirror --single-branch combination does not look right. The "heads/" > part is missing.. It also does not look right for cloning a tag: $ LANG=C ./git clone --single-branch --branch=v1.7.0 .git abc Cloning into 'abc'... done. Note: checking out 'e923eaeb901ff056421b9007adcbbce271caa7b6'. You are in 'detached HEAD' state. You can look around, make experimental changes and commit them, and you can discard any commits you make in this state without impacting any branches by performing another checkout. If you want to create a new branch to retain commits you create, you may do so (now or later) by using -b with the checkout command again. Example: git checkout -b new_branch_name $ grep fetch abc/.git/config fetch = +refs/heads/v1.7.0:refs/remotes/origin/v1.7.0 -- Duy