From: Jeff King Date: Thu, 17 Aug 2023 21:39:02 GMT Subject: Re: clone (single) commit id? Message-ID: <20230817213902.GA3036503@coredump.intra.peff.net> In-Reply-To: On Thu, Aug 17, 2023 at 10:20:20PM +0200, Patrik Hägglund wrote: > As said, I want to use a commit id for reproducability and > performance. The CI flow starts several jobs, all using the same > commit id. A remote branch may be updated, and therefore considered > not good (reproducible) enough as the reference here. Oh, sorry, I didn't realize that was the sticking point. No, sadly I don't think there is any way to feed a direct oid to clone currently. Clone does know how to end up on a detached HEAD (e.g., if you specify a tag with "--branch"). IMHO that would be a useful feature to learn, but I think most folks resort to init+fetch, since it's most often useful in scripted situations (like CI) anyway. -Peff