Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 15 additions & 1 deletion .github/workflows/build-gpui-windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,14 @@ on:
branches: [main, gpui]
pull_request:

# A newer push to the same branch or PR makes an unfinished build of the older
# one pointless, so cancel it instead of letting them pile up. Never on main:
# those builds are the ones that fill the shared cache, and a cancelled run
# saves nothing.
concurrency:
group: build-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}

jobs:
build:
runs-on: windows-latest
Expand All @@ -23,9 +31,15 @@ jobs:

- uses: dtolnay/rust-toolchain@stable

# The installer is its own cargo workspace with its own target folder,
# so it needs its own cache entry. `shared-key` lets release.yml reuse
# what this builds.
- uses: Swatinem/rust-cache@v2
with:
workspaces: gpui
workspaces: |
gpui
gpui/installer
shared-key: windows

# gpui/build.rs bundles the protocol drivers with esbuild, so the root
# node_modules must exist first.
Expand Down
8 changes: 7 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,13 +56,19 @@ jobs:

- uses: dtolnay/rust-toolchain@stable

# Same cache the build workflow fills on main, installer included.
- uses: Swatinem/rust-cache@v2
with:
workspaces: gpui
workspaces: |
gpui
gpui/installer
shared-key: windows

- name: Install JS dependencies
run: npm ci

Comment thread
coderabbitai[bot] marked this conversation as resolved.
# A tag can point at any commit, so don't publish without the tests.
# Cheap now: the shared cache already holds the test build.
- name: Test
run: cargo test
working-directory: gpui
Expand Down
6 changes: 4 additions & 2 deletions gpui/installer/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,9 @@ mslnk = "0.1"
[build-dependencies]
winres = "0.1"

# No LTO here: the installer is a small dialog, and fat LTO over the whole GPUI
# dependency tree was the slowest step of every build for a few percent of size.
[profile.release]
lto = true
codegen-units = 1
lto = false
codegen-units = 16
strip = true
Loading