scripts: installation without sparse-checkout#425
Conversation
Old versions of Ubuntu (and likely other LTS distros) have `git` versions which do not support `git-sparse-checkout`. `git-sparse-checkout` is used as of nodejs#389. Dynamically check if `git sparse-checkout` is supported, and if not then fallback to cloning the whole repo. Cloning the whole repo is _slow_, but at least it works. I tested this patch on Ubuntu 18.04 without any lldb headers installed, and it worked successfully.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #425 +/- ##
==========================================
- Coverage 73.65% 73.57% -0.09%
==========================================
Files 34 34
Lines 4995 4995
==========================================
- Hits 3679 3675 -4
- Misses 1316 1320 +4 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
| '--filter=blob:none', | ||
| '--sparse', | ||
| '--branch', lldbHeadersBranch, | ||
| 'https://github.com/llvm/llvm-project.git', |
There was a problem hiding this comment.
Maybe could we put that one into a variable ?
There was a problem hiding this comment.
Hey @tony-go I'm looking to merge this.
Can you be a bit more specific with the point about the variable?
I'm not 100% on what your ask is.
There was a problem hiding this comment.
I think the ask is to put the Github URL into a variable. I don't feel particularly strongly about it; feel free to do it before merging if you'd like.
There was a problem hiding this comment.
OK this has been around for a while with no updates.
@tony-go I'm also not strongly pushed about changing the implementation.
I'll merge this and please feel free to PR your suggested change if you want.
Old versions of Ubuntu (and likely other LTS distros) have
gitversions which do not supportgit-sparse-checkout.git-sparse-checkoutis used as of #389.Dynamically check if
git sparse-checkoutis supported, and if not then fallback to cloning the whole repo. Cloning the whole repo is slow, but at least it works.I tested this patch on Ubuntu 18.04 without any lldb headers installed, and it worked successfully.