Volume XXII, number 280Wednesday, October 7, 2026Latest message 3 hours ago

The Git List

News and archive of git@vger.kernel.org, since April 2005

patchRe: [PATCH] clone: accept DEPTH env var as fallback for --depth

1 messages between Jun 14, 2026 and Jun 14, 2026, from Hadrien Loge.

Plain Markdown or JSON for tools and agents. Diffs are folded; open one to read it.

Hadrien LogeJun 14, 2026, 08:13 UTC on lore
> So say someone has this set in their environment and then they run a

script that clones a repository and runs `git describe`. That no longer works and the script fails because it assumed that it had history.

That is insightful but that I fail to see how that makes `git` less capable. As Junio pointed there already other ENV vars that do _less_ useful stuff

As to breakage, this is mostly for packaging in clean chroots. If a "history" feature is asked, obviously you skip setting this.

And yes the packages need network to build because they are mostly user generated. For example applying patches to other repos, before building tar archives.

I also fail to see how that would affect existing flows at all?
> because shallow fetches are _extremely_ expensive to serve

That seems like an unrelated issue to my patch yet is also interesting as to why that would be the case. I might actually want to dig into. Because to me, I was saving electrons, at least on my end. And saving time to other packagers.

Thanks for the thoughtful reply. I hope this patch can still be considered Hade

Back to recent threads

Re: [PATCH] clone: accept DEPTH env var as fallback for --depth | The Git List