Skip to content

Commit b56525e

Browse files
authored
Switch to thiserror & update dependencies (#66)
1 parent c7a4ea4 commit b56525e

File tree

10 files changed

+259
-195
lines changed

10 files changed

+259
-195
lines changed

.github/workflows/main.yml

Lines changed: 28 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -10,26 +10,41 @@ env:
1010
CARGO_TERM_COLOR: always
1111

1212
jobs:
13-
cargo-test:
13+
test-linux:
1414
runs-on: ubuntu-latest
1515
steps:
1616
- name: Checkout source
1717
uses: actions/checkout@v2
1818

19-
- name: Get main commit hash
20-
id: main_commit
21-
run: echo "::set-output name=hash::$(git rev-parse origin/main)"
19+
- uses: Swatinem/rust-cache@v1
2220

23-
- name: Cache target, rustup and cargo registry
24-
id: cache-target
25-
uses: actions/cache@v2
21+
- name: cargo test
22+
uses: actions-rs/cargo@v1
23+
with:
24+
command: test
25+
args: --workspace
26+
27+
test-windows:
28+
runs-on: windows-latest
29+
steps:
30+
- name: Checkout source
31+
uses: actions/checkout@v2
32+
33+
- uses: Swatinem/rust-cache@v1
34+
35+
- name: cargo test
36+
uses: actions-rs/cargo@v1
2637
with:
27-
path: |
28-
~/.rustup
29-
~/.cargo/registry
30-
~/.cargo/bin
31-
target
32-
key: main-${{ steps.main_commit.outputs.hash }}
38+
command: test
39+
args: --workspace
40+
41+
test-macos:
42+
runs-on: macos-latest
43+
steps:
44+
- name: Checkout source
45+
uses: actions/checkout@v2
46+
47+
- uses: Swatinem/rust-cache@v1
3348

3449
- name: cargo test
3550
uses: actions-rs/cargo@v1

.github/workflows/pr.yml

Lines changed: 30 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -8,27 +8,13 @@ env:
88
CARGO_TERM_COLOR: always
99

1010
jobs:
11-
cargo-test-and-lint:
11+
test-and-lint:
1212
runs-on: ubuntu-latest
1313
steps:
1414
- name: Checkout source
1515
uses: actions/checkout@v2
1616

17-
- name: Get main commit hash
18-
id: main_commit
19-
run: echo "::set-output name=hash::$(git rev-parse origin/main)"
20-
21-
- name: Cache target, rustup and cargo registry
22-
id: cache-target
23-
uses: actions/cache@v2
24-
with:
25-
path: |
26-
~/.rustup
27-
~/.cargo/registry
28-
~/.cargo/bin
29-
target
30-
key: ${{ github.event.issue.number }}-${{ runner.os }}-pr
31-
restore-keys: main-${{ steps.main_commit.outputs.hash }}
17+
- uses: Swatinem/rust-cache@v1
3218

3319
- name: cargo test
3420
uses: actions-rs/cargo@v1
@@ -47,3 +33,31 @@ jobs:
4733
with:
4834
token: ${{ secrets.GITHUB_TOKEN }}
4935
args: -- -D warnings
36+
37+
test-windows:
38+
runs-on: windows-latest
39+
steps:
40+
- name: Checkout source
41+
uses: actions/checkout@v2
42+
43+
- uses: Swatinem/rust-cache@v1
44+
45+
- name: cargo test
46+
uses: actions-rs/cargo@v1
47+
with:
48+
command: test
49+
args: --workspace
50+
51+
test-macos:
52+
runs-on: macos-latest
53+
steps:
54+
- name: Checkout source
55+
uses: actions/checkout@v2
56+
57+
- uses: Swatinem/rust-cache@v1
58+
59+
- name: cargo test
60+
uses: actions-rs/cargo@v1
61+
with:
62+
command: test
63+
args: --workspace

0 commit comments

Comments
 (0)