Skip to content

Commit

Permalink
Update: workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
kanarus committed Feb 15, 2024
1 parent 17c642a commit 7871d2b
Showing 1 changed file with 17 additions and 7 deletions.
24 changes: 17 additions & 7 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,6 @@ jobs:
steps:
- uses: actions/checkout@v4

- name: Install task command
run: sh -c "$(curl --location https://taskfile.dev/install.sh)" -- -d -b /usr/local/bin

- uses: actions-rs/toolchain@v1
with:
toolchain: ${{ matrix.toolchain }}
Expand All @@ -29,11 +26,24 @@ jobs:
id: cache_cargo_tools
uses: actions/cache@v3
with:
key: ${{ runner.os }}-cargo-install
key: ${{ runner.os }}-cargo-install--sqlx-sccache
path: ~/.cargo/bin
- name: Install cargo tools
if: ${{ steps.cache_cargo_tools.outputs.cache-hit != 'true' }}
run: cargo install sqlx-cli --no-default-features --features native-tls,postgres

run: |
cargo install sqlx-cli --no-default-features --features native-tls,postgres
cargo install sccache --locked
- name: Setup fast build environment
run: |
apt install mold clang
echo '[build]' >> ~/.cargo/config.toml
echo 'rustc-wrapper = "/home/kanarus/.cargo/bin/sccache"' >> ~/.cargo/config.toml
echo '[target.x86_64-unknown-linux-gnu]' >> ~/.cargo/config.toml
echo 'linker = "clang"' >> ~/.cargo/config.toml
echo 'rustflags = ["-C", "link-arg=-fuse-ld=/usr/bin/mold"]' >> ~/.cargo/config.toml
- name: Run tasks
run: task test check ${{ matrix.toolchain == 'nightly' && 'bench' || '' }}
run: |
sh -c "$(curl --location https://taskfile.dev/install.sh)" -- -d -b /usr/local/bin
task test check ${{ matrix.toolchain == 'nightly' && 'bench' || '' }}

0 comments on commit 7871d2b

Please sign in to comment.