|
|
Log in / Subscribe / Register

shallow clones are bad?

shallow clones are bad?

Posted Sep 2, 2026 7:38 UTC (Wed) by taladar (subscriber, #68407)
In reply to: shallow clones are bad? by mricon
Parent article: Ryabitsev: Creepy crawlies

I would assume the vast majority of CI wants exactly the content of the current commit a branch points to to build that. Plus maybe some metadata on the commit itself (like its commit hash and tags) to include in the built --version output.


to post comments

shallow clones are bad?

Posted Sep 2, 2026 14:30 UTC (Wed) by mathstuf (subscriber, #69389) [Link]

CI should not point to branches. The forge should reserve a ref for a CI pipeline to use based on the branch (e.g., GitLab uses refs/pipelines/PIPELINE_ID). Just because the branch was on commit X when the pipeline was created doesn't mean that a job started an hour from now won't get commit Y when asking for the same branch name.

Tags are also not populated (by default) when forking, so you may also need a step to fetch tags from the target project in addition to the code from the source project.


Copyright © 2026, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds