Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
ci: Use ReFS for our Windows CI (#23901)
Piotr Osiewicz2442c49048b7
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.ymlindex a49a7ba79bf..0dee4fc06e4 100644--- a/.github/workflows/ci.yml+++ b/.github/workflows/ci.yml@@ -234,35 +234,58 @@ jobs:runs-on: hosted-windows-1steps:# more info here:- https://github.com/rust-lang/cargo/issues/13020+ - name: Create Dev Drive using ReFS+ run: |+ $Volume = New-VHD -Path C:/zed_dev_drive.vhdx -SizeBytes 30GB |+ Mount-VHD -Passthru |+ Initialize-Disk -Passthru |+ New-Partition -AssignDriveLetter -UseMaximumSize |+ Format-Volume -FileSystem ReFS -Confirm:$false -Force+ Write-Output $Volume+ Write-Output "DEV_DRIVE=$($Volume.DriveLetter):" >> $env:GITHUB_ENV- name: Enable longer pathnames for gitrun: git config --system core.longpaths true- name: Checkout repouses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4with:clean: false+ # actions/checkout does not let us clone into anywhere outside ${{ github.workspace }}, so we have to copy the clone...+ - name: Copy Git Repo to Dev Drive+ run: |+ Copy-Item -Path "${{ github.workspace }}" -Destination "${{ env.DEV_DRIVE }}/zed" -Recurse- name: Cache dependenciesuses: swatinem/rust-cache@f0deed1e0edfc6a9be95417288c0e1099b1eeec3 # v2with:save-if: ${{ github.ref == 'refs/heads/main' }}+ workspaces: ${{ env.DEV_DRIVE }}/zedcache-provider: "github"+ env:+ CARGO_HOME: ${{ env.DEV_DRIVE }}/.cargo+ RUSTUP_HOME: ${{ env.DEV_DRIVE }}/.rustup- name: Configure CIrun: |- mkdir -p ./../.cargo- cp ./.cargo/ci-config.toml ./../.cargo/config.toml+ mkdir -p ${{ env.DEV_DRIVE }}/.cargo -ErrorAction Ignore+ cp ./.cargo/ci-config.toml ${{ env.DEV_DRIVE }}/.cargo/config.toml- name: cargo clippy# Windows can't run shell scripts, so we need to use `cargo xtask`.run: cargo xtask clippy+ env:+ CARGO_HOME: ${{ env.DEV_DRIVE }}/.cargo+ RUSTUP_HOME: ${{ env.DEV_DRIVE }}/.rustup- name: Build Zedrun: cargo build+ env:+ CARGO_HOME: ${{ env.DEV_DRIVE }}/.cargo+ RUSTUP_HOME: ${{ env.DEV_DRIVE }}/.rustup# Since the Windows runners are stateful, so we need to remove the config file to prevent potential bug.- name: Clean CI config fileif: always()- run: Remove-Item -Path "./../.cargo" -Recurse -Force+ run: Remove-Item -Path "${{ env.DEV_DRIVE }}/.cargo/config.toml" -Forcebundle-mac:timeout-minutes: 120diff --git a/to_remove.file b/to_remove.filenew file mode 100644index 00000000000..e69de29bb2d