Skip to content

Commit 1774b8a

Browse files
authored
Fix GHA deprecation warnings (#301)
1 parent 9508be9 commit 1774b8a

File tree

5 files changed

+64
-112
lines changed

5 files changed

+64
-112
lines changed

.github/workflows/ci-post-merge.yml

Lines changed: 15 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ jobs:
4242
with:
4343
command: generate-lockfile
4444
- name: Cache Dependencies
45-
uses: Swatinem/rust-cache@v1.2.0
45+
uses: Swatinem/rust-cache@v2.1.0
4646

4747
- name: check minimal
4848
uses: actions-rs/cargo@v1
@@ -72,7 +72,11 @@ jobs:
7272
matrix:
7373
target:
7474
- { name: macOS, os: macos-latest, triple: x86_64-apple-darwin }
75-
- { name: Windows, os: windows-latest, triple: x86_64-pc-windows-msvc }
75+
- {
76+
name: Windows,
77+
os: windows-latest,
78+
triple: x86_64-pc-windows-msvc,
79+
}
7680
version:
7781
- nightly
7882

@@ -83,44 +87,30 @@ jobs:
8387
- uses: actions/checkout@v3
8488

8589
- name: Install ${{ matrix.version }}
86-
uses: actions-rs/toolchain@v1
87-
with:
88-
toolchain: ${{ matrix.version }}-${{ matrix.target.triple }}
89-
profile: minimal
90-
override: true
90+
run: |
91+
rustup install ${{ matrix.version }}-${{ matrix.target.triple }}
92+
rustup override set ${{ matrix.version }}-${{ matrix.target.triple }}
9193
9294
- name: Install cargo-hack
9395
uses: taiki-e/install-action@cargo-hack
9496

9597
- name: Generate Cargo.lock
96-
uses: actions-rs/cargo@v1
97-
with:
98-
command: generate-lockfile
98+
run: cargo generate-lockfile
9999
- name: Cache Dependencies
100-
uses: Swatinem/rust-cache@v1.2.0
100+
uses: Swatinem/rust-cache@v2.1.0
101101

102102
- name: check minimal
103-
uses: actions-rs/cargo@v1
104-
with: { command: ci-min }
103+
run: cargo ci-min
105104

106105
- name: check minimal + examples
107-
uses: actions-rs/cargo@v1
108-
with: { command: ci-check-min-examples }
106+
run: cargo ci-check-min-examples
109107

110108
- name: check default
111-
uses: actions-rs/cargo@v1
112-
with: { command: ci-check }
109+
run: cargo ci-check
113110

114111
- name: tests
115-
uses: actions-rs/cargo@v1
116112
timeout-minutes: 40
117-
with:
118-
command: ci-test
119-
args: >-
120-
--exclude=actix-redis
121-
--exclude=actix-session
122-
--exclude=actix-limitation
123-
-- --nocapture
113+
run: cargo ci-test --exclude=actix-redis --exclude=actix-session --exclude=actix-limitation -- --nocapture
124114

125115
- name: Clear the cargo caches
126116
run: |

.github/workflows/ci.yml

Lines changed: 29 additions & 52 deletions
Original file line numberDiff line numberDiff line change
@@ -36,38 +36,30 @@ jobs:
3636
- uses: actions/checkout@v3
3737

3838
- name: Install ${{ matrix.version }}
39-
uses: actions-rs/toolchain@v1
40-
with:
41-
toolchain: ${{ matrix.version }}-${{ matrix.target.triple }}
42-
profile: minimal
43-
override: true
39+
run: |
40+
rustup install ${{ matrix.version }}-${{ matrix.target.triple }}
41+
rustup override set ${{ matrix.version }}-${{ matrix.target.triple }}
4442
4543
- name: Install cargo-hack
4644
uses: taiki-e/install-action@cargo-hack
4745

4846
- name: Generate Cargo.lock
49-
uses: actions-rs/cargo@v1
50-
with:
51-
command: generate-lockfile
47+
run: cargo generate-lockfile
5248
- name: Cache Dependencies
53-
uses: Swatinem/rust-cache@v1.2.0
49+
uses: Swatinem/rust-cache@v2.1.0
5450

5551
- name: check minimal
56-
uses: actions-rs/cargo@v1
57-
with: { command: ci-min }
52+
run: cargo ci-min
5853

5954
- name: check minimal + examples
60-
uses: actions-rs/cargo@v1
61-
with: { command: ci-check-min-examples }
55+
run: cargo ci-check-min-examples
6256

6357
- name: check default
64-
uses: actions-rs/cargo@v1
65-
with: { command: ci-check }
58+
run: cargo ci-check
6659

6760
- name: tests
68-
uses: actions-rs/cargo@v1
6961
timeout-minutes: 40
70-
with: { command: ci-test }
62+
run: cargo ci-test
7163

7264
- name: Clear the cargo caches
7365
run: |
@@ -80,7 +72,11 @@ jobs:
8072
matrix:
8173
target:
8274
- { name: macOS, os: macos-latest, triple: x86_64-apple-darwin }
83-
- { name: Windows, os: windows-latest, triple: x86_64-pc-windows-msvc }
75+
- {
76+
name: Windows,
77+
os: windows-latest,
78+
triple: x86_64-pc-windows-msvc,
79+
}
8480
version:
8581
- 1.59 # MSRV
8682
- stable
@@ -92,43 +88,30 @@ jobs:
9288
- uses: actions/checkout@v3
9389

9490
- name: Install ${{ matrix.version }}
95-
uses: actions-rs/toolchain@v1
96-
with:
97-
toolchain: ${{ matrix.version }}-${{ matrix.target.triple }}
98-
profile: minimal
99-
override: true
91+
run: |
92+
rustup install ${{ matrix.version }}-${{ matrix.target.triple }}
93+
rustup override set ${{ matrix.version }}-${{ matrix.target.triple }}
10094
10195
- name: Install cargo-hack
10296
uses: taiki-e/install-action@cargo-hack
10397

10498
- name: Generate Cargo.lock
105-
uses: actions-rs/cargo@v1
106-
with:
107-
command: generate-lockfile
99+
run: cargo generate-lockfile
108100
- name: Cache Dependencies
109-
uses: Swatinem/rust-cache@v1.2.0
101+
uses: Swatinem/rust-cache@v2.1.0
110102

111103
- name: check minimal
112-
uses: actions-rs/cargo@v1
113-
with: { command: ci-min }
104+
run: cargo ci-min
114105

115106
- name: check minimal + examples
116-
uses: actions-rs/cargo@v1
117-
with: { command: ci-check-min-examples }
107+
run: cargo ci-check-min-examples
118108

119109
- name: check default
120-
uses: actions-rs/cargo@v1
121-
with: { command: ci-check }
110+
run: cargo ci-check
122111

123112
- name: tests
124-
uses: actions-rs/cargo@v1
125113
timeout-minutes: 40
126-
with:
127-
command: ci-test
128-
args: >-
129-
--exclude=actix-redis
130-
--exclude=actix-session
131-
--exclude=actix-limitation
114+
run: cargo ci-test --exclude=actix-redis --exclude=actix-session --exclude=actix-limitation
132115

133116
- name: Clear the cargo caches
134117
run: |
@@ -142,21 +125,15 @@ jobs:
142125
- uses: actions/checkout@v3
143126

144127
- name: Install Rust (nightly)
145-
uses: actions-rs/toolchain@v1
146-
with:
147-
toolchain: nightly-x86_64-unknown-linux-gnu
148-
profile: minimal
149-
override: true
128+
run: |
129+
rustup install nightly
130+
rustup override set nightly
150131
151132
- name: Generate Cargo.lock
152-
uses: actions-rs/cargo@v1
153-
with: { command: generate-lockfile }
133+
run: cargo generate-lockfile
154134
- name: Cache Dependencies
155-
uses: Swatinem/rust-cache@v1.3.0
135+
uses: Swatinem/rust-cache@v2.1.0
156136

157137
- name: doc tests
158-
uses: actions-rs/cargo@v1
159138
timeout-minutes: 40
160-
with:
161-
command: ci-doctest
162-
args: -- --nocapture
139+
run: cargo ci-doctest -- --nocapture

.github/workflows/coverage.yml

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -21,22 +21,19 @@ jobs:
2121
- uses: actions/checkout@v3
2222

2323
- name: Install stable
24-
uses: actions-rs/toolchain@v1
25-
with:
26-
toolchain: stable-x86_64-unknown-linux-gnu
27-
profile: minimal
28-
override: true
24+
run: |
25+
rustup override set stable
26+
rustup update stable
2927
3028
- name: Generate Cargo.lock
31-
uses: actions-rs/cargo@v1
32-
with: { command: generate-lockfile }
29+
run: cargo generate-lockfile
3330
- name: Cache Dependencies
34-
uses: Swatinem/rust-cache@v1.2.0
31+
uses: Swatinem/rust-cache@v2.1.0
3532

3633
- name: Generate coverage file
3734
run: |
3835
cargo install cargo-tarpaulin --vers "^0.13"
3936
cargo tarpaulin --workspace --out Xml --verbose
4037
- name: Upload to Codecov
41-
uses: codecov/codecov-action@v1
38+
uses: codecov/codecov-action@v3
4239
with: { file: cobertura.xml }

.github/workflows/lint.yml

Lines changed: 10 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -11,29 +11,22 @@ jobs:
1111
- uses: actions/checkout@v3
1212

1313
- name: Install Rust
14-
uses: actions-rs/toolchain@v1
15-
with:
16-
toolchain: nightly
17-
components: rustfmt
14+
run: |
15+
rustup override set nightly
16+
rustup update nightly
17+
rustup component add rustfmt
1818
- name: Check with rustfmt
19-
uses: actions-rs/cargo@v1
20-
with:
21-
command: fmt
22-
args: --all -- --check
19+
run: cargo fmt --all -- --check
2320

2421
clippy:
2522
runs-on: ubuntu-latest
2623
steps:
2724
- uses: actions/checkout@v3
2825

2926
- name: Install Rust
30-
uses: actions-rs/toolchain@v1
31-
with:
32-
toolchain: stable
33-
components: clippy
34-
override: true
27+
run: |
28+
rustup override set stable
29+
rustup update stable
30+
rustup component add rustfmt
3531
- name: Check with Clippy
36-
uses: actions-rs/clippy-check@v1
37-
with:
38-
token: ${{ secrets.GITHUB_TOKEN }}
39-
args: --workspace --tests --all-features
32+
run: cargo clippy --workspace --tests --all-features

.github/workflows/upload-doc.yml

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -12,17 +12,12 @@ jobs:
1212
- uses: actions/checkout@v3
1313

1414
- name: Install Rust
15-
uses: actions-rs/toolchain@v1
16-
with:
17-
toolchain: nightly-x86_64-unknown-linux-gnu
18-
profile: minimal
19-
override: true
15+
run: |
16+
rustup override set nightly
17+
rustup update nightly
2018
2119
- name: Build Docs
22-
uses: actions-rs/cargo@v1
23-
with:
24-
command: doc
25-
args: --workspace --all-features --no-deps
20+
run: cargo doc --workspace --all-features --no-deps
2621

2722
- name: Tweak HTML
2823
run: echo '<meta http-equiv="refresh" content="0;url=actix_cors/index.html">' > target/doc/index.html

0 commit comments

Comments
 (0)