Skip to content
Permalink
Browse files

TC Windows: Use generic-worker "raw mounts" for the sparse-checkout file

  • Loading branch information...
SimonSapin committed Feb 15, 2019
1 parent ddb85a9 commit c39dbb81e33fa241ca5dc06224ec8fd30c92e69f
Showing with 5 additions and 4 deletions.
  1. +5 −4 etc/taskcluster/decisionlib.py
@@ -431,14 +431,15 @@ def with_repo(self, sparse_checkout=None):
cd repo
"""
if sparse_checkout:
self.with_mounts({
"file": "sparse-checkout",
"content": {"raw": "\n".join(sparse_checkout)},
})
git += """
git config core.sparsecheckout true
echo %SPARSE_CHECKOUT_BASE64% > .git\\info\\sparse.b64
certutil -decode .git\\info\\sparse.b64 .git\\info\\sparse-checkout
copy ..\\sparse-checkout .git\\info\\sparse-checkout
type .git\\info\\sparse-checkout
"""
self.env["SPARSE_CHECKOUT_BASE64"] = base64.b64encode(
"\n".join(sparse_checkout).encode("utf-8"))
git += """
git fetch --depth 1 %GIT_URL% %GIT_REF%
git reset --hard %GIT_SHA%

0 comments on commit c39dbb8

Please sign in to comment.
You can’t perform that action at this time.