From d0a2a34e2ca5e082115f1af924fa88e7446f5cd0 Mon Sep 17 00:00:00 2001 From: Emanuele Stoppa Date: Sun, 30 Apr 2023 19:29:01 +0100 Subject: [PATCH] ci: use maintained action --- .github/workflows/bench_analyzer.yml | 7 +------ .github/workflows/bench_cli.yml | 7 +------ .github/workflows/bench_formatter.yml | 7 +------ .github/workflows/bench_parser.yml | 7 +------ .github/workflows/parser_conformance.yml | 7 +------ .github/workflows/pull_request.yml | 6 +++--- .github/workflows/pull_request_js.yml | 6 ++---- .github/workflows/release_lsp.yml | 6 ++++-- .github/workflows/runtime.yml | 6 ++---- 9 files changed, 16 insertions(+), 43 deletions(-) diff --git a/.github/workflows/bench_analyzer.yml b/.github/workflows/bench_analyzer.yml index 74fda0b84fd..cf816ab5fad 100644 --- a/.github/workflows/bench_analyzer.yml +++ b/.github/workflows/bench_analyzer.yml @@ -33,12 +33,7 @@ jobs: ref: ${{ steps.sha.outputs.result }} - name: Install toolchain - run: rustup show - - - name: Cache - uses: Swatinem/rust-cache@v2 - with: - shared-key: "xtask-release" + uses: moonrepo/setup-rust@v0 - name: Install critcmp run: cargo install critcmp diff --git a/.github/workflows/bench_cli.yml b/.github/workflows/bench_cli.yml index a497fc6b17b..eb38586b170 100644 --- a/.github/workflows/bench_cli.yml +++ b/.github/workflows/bench_cli.yml @@ -33,12 +33,7 @@ jobs: ref: ${{ steps.sha.outputs.result }} - name: Install toolchain - run: rustup show - - - name: Cache - uses: Swatinem/rust-cache@v2 - with: - shared-key: "cli-release" + uses: moonrepo/setup-rust@v0 - name: Install hyperfine run: cargo install hyperfine diff --git a/.github/workflows/bench_formatter.yml b/.github/workflows/bench_formatter.yml index d4b2abae45f..216e4e0dc30 100644 --- a/.github/workflows/bench_formatter.yml +++ b/.github/workflows/bench_formatter.yml @@ -33,12 +33,7 @@ jobs: ref: ${{ steps.sha.outputs.result }} - name: Install toolchain - run: rustup show - - - name: Cache - uses: Swatinem/rust-cache@v2 - with: - shared-key: "xtask-release" + uses: moonrepo/setup-rust@v0 - name: Install critcmp run: cargo install critcmp diff --git a/.github/workflows/bench_parser.yml b/.github/workflows/bench_parser.yml index 5d6f06928eb..9d7f7519fb1 100644 --- a/.github/workflows/bench_parser.yml +++ b/.github/workflows/bench_parser.yml @@ -32,12 +32,7 @@ jobs: ref: ${{ steps.sha.outputs.result }} - name: Install toolchain - run: rustup show - - - name: Cache - uses: Swatinem/rust-cache@v2 - with: - shared-key: "xtask-release" + uses: moonrepo/setup-rust@v0 - name: Install critcmp run: cargo install critcmp diff --git a/.github/workflows/parser_conformance.yml b/.github/workflows/parser_conformance.yml index 29ce1a25dee..3308860dffb 100644 --- a/.github/workflows/parser_conformance.yml +++ b/.github/workflows/parser_conformance.yml @@ -40,12 +40,7 @@ jobs: submodules: recursive - name: Install toolchain - run: rustup show - - - name: Cache - uses: Swatinem/rust-cache@v2 - with: - shared-key: "xtask-release" + uses: moonrepo/setup-rust@v0 - name: Compile run: cargo build --release --locked -p xtask_coverage diff --git a/.github/workflows/pull_request.yml b/.github/workflows/pull_request.yml index d1b2c794c4a..b706b7f2d71 100644 --- a/.github/workflows/pull_request.yml +++ b/.github/workflows/pull_request.yml @@ -28,7 +28,7 @@ jobs: with: components: rustfmt - name: Run rustfmt - run: cargo fmt --all --verbose -- --check + run: cargo fmt --all --check lint: name: Lint Rust Files @@ -76,8 +76,8 @@ jobs: uses: actions/checkout@v3 - name: Install toolchain uses: moonrepo/setup-rust@v0 - - name: Install latest nextest release - uses: taiki-e/install-action@nextest + with: + bins: nextest - name: Compile for tests run: cargo test --no-run --workspace --verbose - name: Run tests diff --git a/.github/workflows/pull_request_js.yml b/.github/workflows/pull_request_js.yml index 32758acd8fe..996c83ca42b 100644 --- a/.github/workflows/pull_request_js.yml +++ b/.github/workflows/pull_request_js.yml @@ -48,10 +48,8 @@ jobs: - uses: pnpm/action-setup@v2.1.0 with: version: 7 - - name: Cache - uses: Swatinem/rust-cache@v2 - with: - shared-key: "wasm" + - name: Install toolchain + uses: moonrepo/setup-rust@v0 - name: Build WASM module for the web run: wasm-pack build --out-dir ../../npm/wasm-web --target web --scope rometools crates/rome_wasm - name: Install libraries diff --git a/.github/workflows/release_lsp.yml b/.github/workflows/release_lsp.yml index bf7845f3269..6a65e74ac64 100644 --- a/.github/workflows/release_lsp.yml +++ b/.github/workflows/release_lsp.yml @@ -109,8 +109,10 @@ jobs: with: fetch-depth: 1 - - name: Install Rust toolchain - run: rustup target add ${{ matrix.target }} + - name: Install toolchain + uses: moonrepo/setup-rust@v0 + with: + targets: ${{ matrix.target }} - name: Install arm64 toolchain if: matrix.code-target == 'linux-arm64' diff --git a/.github/workflows/runtime.yml b/.github/workflows/runtime.yml index 76245839039..bf6385d3dfe 100644 --- a/.github/workflows/runtime.yml +++ b/.github/workflows/runtime.yml @@ -41,10 +41,8 @@ jobs: - uses: pnpm/action-setup@v2.1.0 with: version: 7 - - name: Cache - uses: Swatinem/rust-cache@v2 - with: - shared-key: "wasm" + - name: Install toolchain + uses: moonrepo/setup-rust@v0 - name: Install libraries working-directory: npm/js-api run: pnpm i