Skip to content

armgit / zed

Public Imported from GitHub
0

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.

Download wasi-sdk before cleaning the target directory (#63579)

Kirill Bulatov239d0aa15838
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
index 0e59362fddc..037bc5bda53 100644
--- a/.github/workflows/release.yml
+++ b/.github/workflows/release.yml
@@ -40,6 +40,8 @@ jobs:
tool: nextest
- name: steps::clear_target_dir_if_large
run: ./script/clear-target-dir-if-larger-than 350 200
+ - name: steps::download_wasi_sdk
+ run: ./script/download-wasi-sdk
- name: steps::setup_sccache
run: ./script/setup-sccache
env:
@@ -78,8 +80,6 @@ jobs:
path: ~/.rustup
- name: steps::setup_linux
run: ./script/linux
- - name: steps::download_wasi_sdk
- run: ./script/download-wasi-sdk
- name: steps::setup_node
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e
with:
@@ -92,6 +92,8 @@ jobs:
tool: nextest
- name: steps::clear_target_dir_if_large
run: ./script/clear-target-dir-if-larger-than 350 200
+ - name: steps::download_wasi_sdk
+ run: ./script/download-wasi-sdk
- name: steps::setup_sccache
run: ./script/setup-sccache
env:
diff --git a/.github/workflows/release_nightly.yml b/.github/workflows/release_nightly.yml
index 75f5708fe1f..45cc17f9706 100644
--- a/.github/workflows/release_nightly.yml
+++ b/.github/workflows/release_nightly.yml
@@ -57,8 +57,6 @@ jobs:
path: ~/.rustup
- name: steps::setup_linux
run: ./script/linux
- - name: steps::download_wasi_sdk
- run: ./script/download-wasi-sdk
- name: steps::setup_node
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e
with:
@@ -71,6 +69,8 @@ jobs:
tool: nextest
- name: steps::clear_target_dir_if_large
run: ./script/clear-target-dir-if-larger-than 350 200
+ - name: steps::download_wasi_sdk
+ run: ./script/download-wasi-sdk
- name: steps::setup_sccache
run: ./script/setup-sccache
env:
diff --git a/.github/workflows/run_tests.yml b/.github/workflows/run_tests.yml
index d5b96c76158..bf7b83a7bff 100644
--- a/.github/workflows/run_tests.yml
+++ b/.github/workflows/run_tests.yml
@@ -394,8 +394,6 @@ jobs:
path: ~/.rustup
- name: steps::setup_linux
run: ./script/linux
- - name: steps::download_wasi_sdk
- run: ./script/download-wasi-sdk
- name: steps::setup_node
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e
with:
@@ -408,6 +406,8 @@ jobs:
tool: nextest
- name: steps::clear_target_dir_if_large
run: ./script/clear-target-dir-if-larger-than 350 200
+ - name: steps::download_wasi_sdk
+ run: ./script/download-wasi-sdk
- name: steps::setup_sccache
run: ./script/setup-sccache
env:
@@ -463,6 +463,8 @@ jobs:
tool: nextest
- name: steps::clear_target_dir_if_large
run: ./script/clear-target-dir-if-larger-than 350 200
+ - name: steps::download_wasi_sdk
+ run: ./script/download-wasi-sdk
- name: steps::setup_sccache
run: ./script/setup-sccache
env:
diff --git a/tooling/xtask/src/tasks/workflows/run_tests.rs b/tooling/xtask/src/tasks/workflows/run_tests.rs
index ce44c05fc46..68470fe7998 100644
--- a/tooling/xtask/src/tasks/workflows/run_tests.rs
+++ b/tooling/xtask/src/tasks/workflows/run_tests.rs
@@ -626,16 +626,19 @@ fn run_platform_tests_impl(platform: Platform, filter_packages: bool, harden: bo
.when(platform == Platform::Linux, |this| {
use_clang(this.add_step(steps::cache_rust_dependencies_namespace()))
})
- .when(
- platform == Platform::Linux,
- steps::install_linux_dependencies,
- )
+ .when(platform == Platform::Linux, |job| {
+ job.add_step(steps::setup_linux())
+ })
.add_step(steps::setup_node())
.when(
platform == Platform::Linux || platform == Platform::Mac,
|job| job.add_step(steps::cargo_install_nextest()),
)
.add_step(steps::clear_target_dir_if_large(platform))
+ .when(
+ platform == Platform::Linux || platform == Platform::Mac,
+ |job| job.add_step(steps::download_wasi_sdk()),
+ )
.add_step(steps::setup_sccache(platform))
.when(filter_packages, |job| {
job.add_step(
diff --git a/tooling/xtask/src/tasks/workflows/steps.rs b/tooling/xtask/src/tasks/workflows/steps.rs
index 754995d9cb1..d60a411966e 100644
--- a/tooling/xtask/src/tasks/workflows/steps.rs
+++ b/tooling/xtask/src/tasks/workflows/steps.rs
@@ -322,7 +322,7 @@ pub fn setup_linux() -> Step<Run> {
named::bash("./script/linux")
}
-fn download_wasi_sdk() -> Step<Run> {
+pub(crate) fn download_wasi_sdk() -> Step<Run> {
named::bash("./script/download-wasi-sdk")
}