@@ -18,25 +18,25 @@ jobs:
18
18
- stable-x86_64-unknown-linux-gnu
19
19
20
20
name : Rustfmt (${{ matrix.toolchain }})
21
- runs-on : ubuntu-18 .04
21
+ runs-on : ubuntu-20 .04
22
22
23
23
steps :
24
24
- name : Checkout
25
- uses : actions/checkout@v2
25
+ uses : actions/checkout@v3
26
26
27
27
- name : ' Setup `${{ matrix.toolchain }}`'
28
- uses : actions-rs/ toolchain@v1
28
+ uses : dtolnay/rust- toolchain@master
29
29
with :
30
30
toolchain : ${{ matrix.toolchain }}
31
- override : true
32
- profile : minimal
33
31
components : rustfmt
34
32
33
+ - name : ' Override `${{ matrix.toolchain }}'
34
+ run : |
35
+ rustup override set ${{ matrix.toolchain }}
36
+
35
37
- name : cargo-fmt
36
- uses : actions-rs/cargo@v1
37
- with :
38
- command : fmt
39
- args : --all -- --check
38
+ run : |
39
+ cargo fmt --all -- --check
40
40
41
41
build :
42
42
strategy :
@@ -51,11 +51,11 @@ jobs:
51
51
- stable-x86_64-unknown-linux-gnu
52
52
include :
53
53
- { toolchain: 1.42.0-x86_64-pc-windows-msvc , os: windows-2019 }
54
- - { toolchain: 1.42.0-x86_64-apple-darwin , os: macos-10.15 }
55
- - { toolchain: 1.42.0-x86_64-unknown-linux-gnu, os: ubuntu-18 .04 }
54
+ - { toolchain: 1.42.0-x86_64-apple-darwin , os: macos-11 }
55
+ - { toolchain: 1.42.0-x86_64-unknown-linux-gnu, os: ubuntu-20 .04 }
56
56
- { toolchain: stable-x86_64-pc-windows-msvc , os: windows-2019 }
57
- - { toolchain: stable-x86_64-apple-darwin , os: macos-10.15 }
58
- - { toolchain: stable-x86_64-unknown-linux-gnu, os: ubuntu-18 .04 }
57
+ - { toolchain: stable-x86_64-apple-darwin , os: macos-11 }
58
+ - { toolchain: stable-x86_64-unknown-linux-gnu, os: ubuntu-20 .04 }
59
59
60
60
name : Build (${{ matrix.toolchain }})
61
61
runs-on : ${{ matrix.os }}
@@ -66,33 +66,29 @@ jobs:
66
66
if : matrix.os == 'windows-2019'
67
67
68
68
- name : Checkout
69
- uses : actions/checkout@v2
69
+ uses : actions/checkout@v3
70
70
71
71
- name : ' Setup `${{ matrix.toolchain }}`'
72
- uses : actions-rs/ toolchain@v1
72
+ uses : dtolnay/rust- toolchain@master
73
73
with :
74
74
toolchain : ${{ matrix.toolchain }}
75
- override : true
76
- profile : minimal
77
75
components : clippy
78
76
77
+ - name : ' Override `${{ matrix.toolchain }}`'
78
+ run : |
79
+ rustup override set ${{ matrix.toolchain }}
80
+
79
81
- name : cargo-clippy
80
- uses : actions-rs/cargo@v1
81
- with :
82
- command : clippy
83
- args : --workspace --all-targets -- -D warnings
82
+ run : |
83
+ cargo clippy --workspace --all-targets -- -A renamed-and-removed-lints -D warnings
84
84
85
85
- name : cargo-build
86
- uses : actions-rs/cargo@v1
87
- with :
88
- command : build
89
- args : --workspace --all-targets
86
+ run : |
87
+ cargo build --workspace --all-targets
90
88
91
89
- name : cargo-test
92
- uses : actions-rs/cargo@v1
93
- with :
94
- command : test
95
- args : --workspace --no-fail-fast
90
+ run : |
91
+ cargo test --workspace --no-fail-fast
96
92
env :
97
93
RUST_BACKTRACE : full
98
94
@@ -108,22 +104,24 @@ jobs:
108
104
- ' 3.8' # https://packages.ubuntu.com/focal/python3
109
105
110
106
name : Expand_test (${{ matrix.toolchain }}, ${{ matrix.python-version }})
111
- runs-on : ubuntu-18 .04
107
+ runs-on : ubuntu-20 .04
112
108
113
109
steps :
114
110
- name : Checkout
115
- uses : actions/checkout@v2
111
+ uses : actions/checkout@v3
116
112
117
113
- name : ' Setup `${{ matrix.toolchain }}`'
118
- uses : actions-rs/ toolchain@v1
114
+ uses : dtolnay/rust- toolchain@master
119
115
with :
120
116
toolchain : ${{ matrix.toolchain }}
121
- override : true
122
- profile : minimal
123
117
components : rustfmt
124
118
119
+ - name : ' Override `${{ matrix.toolchain }}`'
120
+ run : |
121
+ rustup override set ${{ matrix.toolchain }}
122
+
125
123
- name : Setup Python ${{ matrix.python-version }}
126
- uses : actions/setup-python@v2
124
+ uses : actions/setup-python@v4
127
125
with :
128
126
python-version : ${{ matrix.python-version }}
129
127
@@ -136,28 +134,28 @@ jobs:
136
134
137
135
steps :
138
136
- name : Checkout
139
- uses : actions/checkout@v2
137
+ uses : actions/checkout@v3
140
138
141
- - name : Setup `1.47 .0-x86_64-unknown-linux-gnu`
142
- uses : actions-rs/ toolchain@v1
139
+ - name : Setup `1.60 .0-x86_64-unknown-linux-gnu`
140
+ uses : dtolnay/rust- toolchain@master
143
141
with :
144
- toolchain : 1.47.0-x86_64-unknown-linux-gnu
145
- override : true
146
- profile : minimal
142
+ toolchain : 1.60.0-x86_64-unknown-linux-gnu
143
+
144
+ - name : ' Override `1.60.0-x86_64-unknown-linux-gnu'
145
+ run : |
146
+ rustup override set 1.60.0-x86_64-unknown-linux-gnu
147
147
148
148
- name : Setup Python 3.9
149
- uses : actions/setup-python@v2
149
+ uses : actions/setup-python@v4
150
150
with :
151
151
python-version : ' 3.9'
152
152
153
153
- name : Install `oj`
154
154
run : pip install online-judge-tools
155
155
156
156
- name : cargo-build
157
- uses : actions-rs/cargo@v1
158
- with :
159
- command : build
160
- args : --release --examples
157
+ run : |
158
+ cargo build --release --examples
161
159
162
160
- name : Verify
163
161
run : |
0 commit comments