Skip to content

Commit

Permalink
Bump rust gh action to v1 and define toolchain version
Browse files Browse the repository at this point in the history
  • Loading branch information
adzialocha committed Jun 14, 2024
1 parent 3ebf106 commit 6da24b0
Showing 1 changed file with 21 additions and 8 deletions.
29 changes: 21 additions & 8 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on: push

env:
CARGO_TERM_COLOR: always
RUST_TOOLCHAIN: 1.79.0
cargo_manifest: aquadoggo/Cargo.toml

jobs:
Expand All @@ -18,8 +19,9 @@ jobs:
uses: actions/checkout@v3

- name: Setup Rust toolchain
uses: moonrepo/setup-rust@v0
uses: moonrepo/setup-rust@v1
with:
channel: ${{ env.RUST_TOOLCHAIN }}
cache-target: release

- name: Build binary
Expand All @@ -40,7 +42,9 @@ jobs:
uses: actions/checkout@v3

- name: Setup Rust toolchain
uses: moonrepo/setup-rust@v0
uses: moonrepo/setup-rust@v1
with:
channel: ${{ env.RUST_TOOLCHAIN }}

# Related issue: https://github.com/p2panda/aquadoggo/issues/414
- name: Temporary workaround for rustc bug
Expand Down Expand Up @@ -81,7 +85,9 @@ jobs:
uses: actions/checkout@v3

- name: Setup Rust toolchain
uses: moonrepo/setup-rust@v0
uses: moonrepo/setup-rust@v1
with:
channel: ${{ env.RUST_TOOLCHAIN }}

# Related issue: https://github.com/p2panda/aquadoggo/issues/414
- name: Temporary workaround for rustc bug
Expand All @@ -108,7 +114,9 @@ jobs:
uses: actions/checkout@v3

- name: Setup Rust toolchain
uses: moonrepo/setup-rust@v0
uses: moonrepo/setup-rust@v1
with:
channel: ${{ env.RUST_TOOLCHAIN }}

- name: Run tests
run: |
Expand All @@ -127,7 +135,9 @@ jobs:
uses: actions/checkout@v3

- name: Setup Rust toolchain
uses: moonrepo/setup-rust@v0
uses: moonrepo/setup-rust@v1
with:
channel: ${{ env.RUST_TOOLCHAIN }}

- name: Check project and dependencies
run: |
Expand All @@ -142,8 +152,9 @@ jobs:
uses: actions/checkout@v3

- name: Setup Rust toolchain
uses: moonrepo/setup-rust@v0
uses: moonrepo/setup-rust@v1
with:
channel: ${{ env.RUST_TOOLCHAIN }}
components: rustfmt

- name: Check formatting
Expand All @@ -163,8 +174,9 @@ jobs:
uses: actions/checkout@v3

- name: Setup Rust toolchain
uses: moonrepo/setup-rust@v0
uses: moonrepo/setup-rust@v1
with:
channel: ${{ env.RUST_TOOLCHAIN }}
components: clippy

- name: Check code with clippy
Expand All @@ -184,8 +196,9 @@ jobs:
uses: actions/checkout@v3

- name: Setup Rust toolchain
uses: moonrepo/setup-rust@v0
uses: moonrepo/setup-rust@v1
with:
channel: ${{ env.RUST_TOOLCHAIN }}
bins: grcov
components: llvm-tools-preview

Expand Down

0 comments on commit 6da24b0

Please sign in to comment.