forked from pop-os/cosmic-comp
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: re-enable nix job build, add caching, refactor
- Loading branch information
Showing
2 changed files
with
32 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
name: Setup Rust | ||
description: Setup Rust environment in latest Ubuntu | ||
steps: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: dtolnay/rust-toolchain@stable | ||
- uses: Swatinem/rust-cache@v2 | ||
- run: sudo apt-get update; sudo apt-get install -y libdrm-dev libudev-dev libgbm-dev libxkbcommon-dev libegl1-mesa-dev libwayland-dev libinput-dev libdbus-1-dev libsystemd-dev libseat-dev | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,32 @@ | ||
name: "Build" | ||
on: | ||
pull_request: | ||
branches: | ||
workflow_dispatch: | ||
pull_request: | ||
branches: | ||
- master | ||
push: | ||
branches: | ||
branches: | ||
- master | ||
jobs: | ||
# build: | ||
# runs-on: ubuntu-latest | ||
# steps: | ||
# - uses: actions/checkout@v3 | ||
# - uses: cachix/install-nix-action@v22 | ||
# with: | ||
# nix_path: nixpkgs=channel:nixpkgs-unstable | ||
# - run: GIT_LFS_SKIP_SMUDGE=1 nix build | ||
# - run: nix flake check | ||
check-features: | ||
runs-on: ubuntu-latest | ||
build: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: read | ||
id-token: write | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: DeterminateSystems/nix-installer-action@main | ||
- uses: DeterminateSystems/magic-nix-cache-action@main | ||
- run: nix flake check --print-build-logs --keep-going | ||
check-no-default-features: | ||
uses: ./.github/actions/rust-env | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: dtolnay/rust-toolchain@stable | ||
- run: sudo apt-get update; sudo apt-get install -y libdrm-dev libudev-dev libgbm-dev libxkbcommon-dev libegl1-mesa-dev libwayland-dev libinput-dev libdbus-1-dev libsystemd-dev libseat-dev | ||
- run: cargo check --no-default-features | ||
check-debug-feature: | ||
uses: ./.github/actions/rust-env | ||
steps: | ||
- run: cargo check --features debug | ||
check-profile-with-tracy-feature: | ||
uses: ./.github/actions/rust-env | ||
steps: | ||
- run: cargo check --features profile-with-tracy |