Skip to content
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

ci: use "filter: tree:0" #69259

Closed

Conversation

fabiobaltieri
Copy link
Member

just testing...

@fabiobaltieri fabiobaltieri changed the title ci: use "filter: tree:0" instead of "fetch-depth: 0" ci: use "filter: tree:0" Feb 20, 2024
@fabiobaltieri fabiobaltieri force-pushed the ci-filter-tree0 branch 3 times, most recently from be0eba9 to 7a14043 Compare February 20, 2024 18:26
@nashif
Copy link
Member

nashif commented Feb 20, 2024

did it work? whateve that is :)

@fabiobaltieri
Copy link
Member Author

fabiobaltieri commented Feb 20, 2024

did it work? whateve that is :)

I think it works, it tells git to download blobs on demand, it's not as efficient as a shallow clone but not far from it and leaves the full history available, on the compliance check it cuts the checkout time roughly in half, will play a bit more with it.

Saw it in https://youtu.be/aolI_Rz0ZqY?si=HRD-xNpZiuSWPwjR&t=1804 (and also got pointed to it in discord recently)

Add a filter: tree:0 to all workflows that do a full checkout
(fetch-depth: 0) and have no existing cache.

Signed-off-by: Fabio Baltieri <[email protected]>
@fabiobaltieri
Copy link
Member Author

31 seconds for the clone and 0 seconds for the rebase without this, 20 seconds for the clone and 5 seconds for the rebase with this. Not worth it.

@fabiobaltieri fabiobaltieri deleted the ci-filter-tree0 branch February 28, 2024 17:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants