-
Notifications
You must be signed in to change notification settings - Fork 52
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
Improve git clone command in manual #184
Improve git clone command in manual #184
Conversation
By adding `--depth 1`, the command only downloads the latest commit snapshot, thereby saving bandwidth and completing faster. Since the repository is cloned for the purpose of building and installing, it is not important to have the commit history.
I'm not sure this is worth it. Our repository should be pretty small (5-10 MB or so?), and I think shallow clones can be problematic in some cases like doing Finally, this is the wrong repository, the manual is kept next to the source code. |
I think pulling works... Is this the wrong repository for https://rust-analyzer.github.io/manual.html ? |
Hmm, the other open PR, #168 is mentioning https://github.com/rust-analyzer/rust-analyzer/blob/master/docs/user/manual.adoc as the correct repository. it's not the link in the website at the bottom though, so that was a bit confusing. Separate question: do you think the bottom link in https://rust-analyzer.github.io/manual.html should link to https://github.com/rust-analyzer/rust-analyzer/blob/master/docs/user/manual.adoc ? |
See https://github.blog/2020-12-21-get-up-to-speed-with-partial-clone-and-shallow-clone/:
Yes, there's a comment on that theme at the top, any idea on how to make it more visible? |
Maybe it should, but not on the blog and changelog posts. I think it's the same footer on every page. |
Okay, you are right. Actually pulling into a shallow copy seems to not work; you need to complete the history first or re-clone. The stress is put server-side and probably github can deal with it. But also there are no instructions to |
Yes I agree. It can maybe be overridden for single pages, but not sure. |
I think pull actually works for me (it appears to do nothing when there are no new commits).
No, we should play nicely. If everyone said "GitHub can deal with my shallow clone", that would be pretty awful. But It seems we've grown to 64 MB, I wonder if there's anything we could get rid of in there. |
Yeah, it seems our largest objects are an unsquashed GraphQL schema and a lot of |
By adding
--depth 1
, the command only downloads the latest commitsnapshot, thereby saving bandwidth and completing faster.
Since the repository is cloned for the purpose of building and
installing, it is not important to have the commit history.