-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Shallow cloning on travis #1372
Shallow cloning on travis #1372
Conversation
Thanks for your suggestion. A few notes:
So, I don't really care that much either way. |
Thank you, Mr. Widdis. I learned a lot from your reply. |
Looking at My reasoning then had been an experience I had getting CI to run on a commit to a branch that was several hundred commits behind master. Disabling shallow clone fixed it. I don't know enough about the technical details to know if that was a coincidence or not. |
https://stackoverflow.com/questions/31278233/disadvantages-of-shallow-cloning-on-travis-and-other-ci-services, this post give some issues about shallow clone. |
You've got a similar PR on my project so I'm replying twice. I looked at my own history and saw my use of full clone was intentional to support blame information on SonarQube, which was at the time triggered from my Travis build. See https://docs.sonarqube.org/latest/analysis/scm-integration/ We don't trigger any external CI from Travis so this isn't a concern and it's probably reasonable to change it. The time I've spent thinking about this will far exceed the multiples of 10 seconds we'll save, though. :) |
Summarizing my thoughts:
|
@YunLemon please provide a real name and email address contact on the commit, it currently shows as |
CI builds will still run multiple times...and will save multiples of 10 seconds. ^_^ |
Yes. Just remove the config so it uses the default; use a real name and email in your git config; and squash your commits. I'll merge tomorrow if nobody else has any reason not to. |
According to https://docs.travis-ci.com/user/customizing-the-build#git-clone-depth, Travis CI provide a way to shallow clone a repository. This has the obvious benefit of speed, since you only need to download a small number of commits.