about summary refs log tree commit diff
path: root/src/test/run-pass/thinlto
diff options
context:
space:
mode:
authorCorey Farwell <coreyf@rwell.org>2017-03-29 16:53:29 -0400
committerGitHub <noreply@github.com>2017-03-29 16:53:29 -0400
commita9dc8ac7ac5dee13675b01ea7db8a93d90d40cf2 (patch)
treef76cb929c8dd1e4da27b14656a56b4e0a99c330f /src/test/run-pass/thinlto
parente1cec5d4bf626f151a779323e16d62fe60117086 (diff)
parent96e174febdd9e0f3624b59e8411332b3e46eb97b (diff)
downloadrust-a9dc8ac7ac5dee13675b01ea7db8a93d90d40cf2.tar.gz
rust-a9dc8ac7ac5dee13675b01ea7db8a93d90d40cf2.zip
Rollup merge of #40780 - aidanhs:aphs-cache-git-modules, r=alexcrichton
Attempt to cache git modules

Partial resolution of #40772, appveyor remains to be done once travis looks like it's working ok.

The approach in this PR is based on the `--reference` flag to `git-clone`/`git-submodule --update` and is a compromise based on the current limitations of the tools we're using.

The ideal would be:
1. have a cached pristine copy of rust-lang/rust master in `$HOME/rustsrc` with all submodules initialised
2. clone the PR branch with `git clone --recurse-submodules --reference $HOME/rustsrc git@github.com:rust-lang/rust.git`

This would (in the nonexistent ideal world) use the pristine copy as an object cache for the top level repo and all submodules, transferring over the network only the changes on the branch. Unfortunately, a) there is no way to manually control the initial clone with travis and b) even if there was, cloned submodules don't use the submodules of the reference as an object cache. So the steps we end up with are:

1. have a cached pristine copy of rust-lang/rust master in `$HOME/rustsrc` with all submodules initialised
2. have a cloned PR branch
3. extract the path of each submodule, and explicitly `git submodule update --init --reference $HOME/rustsrc/$module $module` (i.e. point directly to the location of the pristine submodule repo) for each one

I've also taken some care to make this forward compatible, both for adding and removing submodules.

r? @alexcrichton
Diffstat (limited to 'src/test/run-pass/thinlto')
0 files changed, 0 insertions, 0 deletions