Browse Source

Update CI pipeline

develop
Silvestr Predko 1 year ago
parent
commit
9cf553c6bf
3 changed files with 12 additions and 13 deletions
  1. 3
    3
      .github/workflows/cd.yml
  2. 8
    9
      .github/workflows/ci.yml
  3. 1
    1
      web-client/Cargo.toml

+ 3
- 3
.github/workflows/cd.yml View File

@@ -21,10 +21,10 @@ jobs:
21 21
           node-version: lts/*
22 22
           registry-url: https://npm.pkg.github.com
23 23
           scope: "@relayz-io"
24
-      - uses: actions-rs/toolchain@v1
24
+      - name: Install Rust Toolchain
25
+        uses: dtolnay/rust-toolchain@stable
25 26
         with:
26
-          toolchain: stable
27
-          target: wasm32-unknown-unknown
27
+          targets: "wasm32-unknown-unknown"
28 28
       - name: Install wasm-pack
29 29
         run: curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh
30 30
       - name: Build an npm package

+ 8
- 9
.github/workflows/ci.yml View File

@@ -20,12 +20,12 @@ jobs:
20 20
     steps:
21 21
       - uses: actions/checkout@v3
22 22
       - name: Install Rust Toolchain
23
-        uses: actions-rs/toolchain@v1
23
+        uses: dtolnay/rust-toolchain@nightly
24 24
         with:
25
-          toolchain: nightly
26 25
           components: rustfmt
26
+      - uses: Swatinem/rust-cache@v2
27 27
       - name: cargo fmt
28
-        run: cargo +nightly fmt -- --check
28
+        run: cargo fmt -- --check
29 29
   clippy:
30 30
     name: clippy
31 31
     needs: fmt
@@ -33,12 +33,12 @@ jobs:
33 33
     steps:
34 34
       - uses: actions/checkout@v3
35 35
       - name: Install Rust Toolchain
36
-        uses: actions-rs/toolchain@v1
36
+        uses: dtolnay/rust-toolchain@nightly
37 37
         with:
38
-          toolchain: nightly
39 38
           components: clippy
39
+      - uses: Swatinem/rust-cache@v2
40 40
       - name: cargo clippy
41
-        run: cargo +nightly clippy --workspace --tests -- -D warnings
41
+        run: cargo clippy --workspace --tests -- -D warnings
42 42
   tests:
43 43
     name: tests
44 44
     needs: [clippy, fmt]
@@ -46,9 +46,8 @@ jobs:
46 46
     steps:
47 47
       - uses: actions/checkout@v3
48 48
       - name: Install Rust Toolchain
49
-        uses: actions-rs/toolchain@v1
50
-        with:
51
-          toolchain: stable
49
+        uses: dtolnay/rust-toolchain@stable
50
+      - uses: Swatinem/rust-cache@v2
52 51
       - name: Run tests for [common-api]
53 52
         run: cargo test --tests --all-features
54 53
   tests-web:

+ 1
- 1
web-client/Cargo.toml View File

@@ -29,7 +29,7 @@ serde-wasm-bindgen = "0.5"
29 29
 serde = { version = "1", default-features = false, features = ["derive"] }
30 30
 serde_json = { version = "1", default-features = false }
31 31
 uuid = { version = "1.3", features = ["v4", "serde", "js"] }
32
-url = "2.2"
32
+url = "2.3"
33 33
 wasm-bindgen = { version = "0.2", features = ["serde-serialize"] }
34 34
 wasm-bindgen-futures = "0.4"
35 35
 web-sys = { version = "0.3", features = ["console"] }

Loading…
Cancel
Save