Skip to content

Commit a8f0eef

Browse files
committed
Update CI
1 parent 7b0b0a0 commit a8f0eef

File tree

1 file changed

+66
-74
lines changed

1 file changed

+66
-74
lines changed

.github/workflows/main.yml

Lines changed: 66 additions & 74 deletions
Original file line numberDiff line numberDiff line change
@@ -8,92 +8,84 @@ jobs:
88
strategy:
99
matrix:
1010
target:
11-
- x86_64-unknown-linux-gnu
12-
- aarch64-unknown-linux-gnu
13-
- mips64-unknown-linux-gnuabi64
14-
- x86_64-apple-darwin
15-
- aarch64-apple-darwin
16-
- x86_64-pc-windows-msvc
17-
rust: [stable]
11+
- x86_64-unknown-linux-gnu
12+
- aarch64-unknown-linux-gnu
13+
- mips64-unknown-linux-gnuabi64
14+
- x86_64-apple-darwin
15+
- aarch64-apple-darwin
16+
- x86_64-pc-windows-msvc
1817
include:
19-
- target: x86_64-unknown-linux-gnu
20-
os: ubuntu-18.04
21-
- target: aarch64-unknown-linux-gnu
22-
os: ubuntu-18.04
23-
- target: mips64-unknown-linux-gnuabi64
24-
os: ubuntu-18.04
25-
- target: x86_64-apple-darwin
26-
os: macos-latest
27-
- target: aarch64-apple-darwin
28-
os: macos-11.0
29-
- target: x86_64-pc-windows-msvc
30-
os: windows-latest
18+
- target: x86_64-unknown-linux-gnu
19+
os: ubuntu-22.04
20+
- target: aarch64-unknown-linux-gnu
21+
os: ubuntu-22.04
22+
- target: mips64-unknown-linux-gnuabi64
23+
os: ubuntu-22.04
24+
- target: x86_64-apple-darwin
25+
os: macos-latest
26+
- target: aarch64-apple-darwin
27+
os: macos-latest
28+
- target: x86_64-pc-windows-msvc
29+
os: windows-latest
3130
steps:
32-
- uses: actions/checkout@v2
33-
with:
34-
submodules: true
35-
- uses: actions-rs/toolchain@v1
36-
with:
37-
toolchain: ${{ matrix.rust }}
38-
target: ${{ matrix.target }}
39-
override: false
40-
- name: Install GCC (aarch64-unknown-linux-gnu)
41-
if: ${{ matrix.target == 'aarch64-unknown-linux-gnu' }}
42-
run: |
43-
sudo apt-get update -y
44-
sudo apt-get install -y --no-install-recommends gcc-aarch64-linux-gnu libc6-dev-arm64-cross
45-
shell: bash
46-
- name: Install GCC (mips64-unknown-linux-gnuabi64)
47-
if: ${{ matrix.target == 'mips64-unknown-linux-gnuabi64' }}
48-
run: |
49-
sudo apt-get update -y
50-
sudo apt-get install -y --no-install-recommends gcc-mips64-linux-gnuabi64 libc6-dev-mips64-cross
51-
shell: bash
52-
- name: Build ${{ matrix.lua }}
53-
run: |
54-
cargo build --manifest-path testcrate/Cargo.toml --target ${{ matrix.target }} --release
55-
shell: bash
31+
- uses: actions/checkout@v3
32+
with:
33+
submodules: true
34+
- uses: dtolnay/rust-toolchain@stable
35+
with:
36+
target: ${{ matrix.target }}
37+
- name: Install GCC (aarch64-unknown-linux-gnu)
38+
if: ${{ matrix.target == 'aarch64-unknown-linux-gnu' }}
39+
run: |
40+
sudo apt-get update -y
41+
sudo apt-get install -y --no-install-recommends gcc-aarch64-linux-gnu libc6-dev-arm64-cross
42+
shell: bash
43+
- name: Install GCC (mips64-unknown-linux-gnuabi64)
44+
if: ${{ matrix.target == 'mips64-unknown-linux-gnuabi64' }}
45+
run: |
46+
sudo apt-get update -y
47+
sudo apt-get install -y --no-install-recommends gcc-mips64-linux-gnuabi64 libc6-dev-mips64-cross
48+
shell: bash
49+
- name: Build ${{ matrix.lua }}
50+
run: |
51+
cargo build --manifest-path testcrate/Cargo.toml --target ${{ matrix.target }} --release
52+
shell: bash
5653

5754
test:
5855
name: Test
5956
runs-on: ${{ matrix.os }}
6057
needs: build
6158
strategy:
6259
matrix:
63-
os: [ubuntu-18.04, macos-latest, windows-latest]
64-
rust: [stable]
60+
os: [ubuntu-22.04, macos-latest, windows-latest]
6561
include:
66-
- os: ubuntu-18.04
67-
target: x86_64-unknown-linux-gnu
68-
- os: macos-latest
69-
target: x86_64-apple-darwin
70-
- os: windows-latest
71-
target: x86_64-pc-windows-msvc
62+
- os: ubuntu-22.04
63+
target: x86_64-unknown-linux-gnu
64+
- os: macos-latest
65+
target: x86_64-apple-darwin
66+
- os: windows-latest
67+
target: x86_64-pc-windows-msvc
7268
steps:
73-
- uses: actions/checkout@v2
74-
with:
75-
submodules: true
76-
- uses: actions-rs/toolchain@v1
77-
with:
78-
toolchain: ${{ matrix.rust }}
79-
target: ${{ matrix.target }}
80-
override: true
81-
- name: Run ${{ matrix.lua }} tests
82-
run: |
83-
cargo test --manifest-path testcrate/Cargo.toml --release
84-
cargo test --manifest-path testcrate/Cargo.toml --release --features lua52compat
85-
shell: bash
69+
- uses: actions/checkout@v3
70+
with:
71+
submodules: true
72+
- uses: dtolnay/rust-toolchain@stable
73+
with:
74+
target: ${{ matrix.target }}
75+
- name: Run ${{ matrix.lua }} tests
76+
run: |
77+
cargo test --manifest-path testcrate/Cargo.toml --release
78+
cargo test --manifest-path testcrate/Cargo.toml --release --features lua52compat
79+
shell: bash
8680

8781
rustfmt:
8882
name: Rustfmt
89-
runs-on: ubuntu-18.04
83+
runs-on: ubuntu-22.04
9084
steps:
91-
- uses: actions/checkout@v2
92-
with:
93-
submodules: true
94-
- uses: actions-rs/toolchain@v1
95-
with:
96-
toolchain: stable
97-
components: rustfmt
98-
override: true
99-
- run: cargo fmt -- --check
85+
- uses: actions/checkout@v3
86+
with:
87+
submodules: true
88+
- uses: dtolnay/rust-toolchain@stable
89+
with:
90+
components: rustfmt
91+
- run: cargo fmt -- --check

0 commit comments

Comments
 (0)