Skip to content

Commit 0493907

Browse files
committed
Remove Godot from CI where possible (clippy, test)
1 parent c20197f commit 0493907

File tree

4 files changed

+18
-94
lines changed

4 files changed

+18
-94
lines changed

.github/composite/llvm/action.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ runs:
2424
- name: "Cache LLVM and clang"
2525
id: cache-llvm
2626
# Note: conditionals not yet supported; see https://github.com/actions/runner/issues/834
27-
# if: ${{ inputs.llvm == 'true' }}
27+
# if: inputs.llvm == 'true'
2828
uses: actions/cache@v3
2929
with:
3030
# path: |
@@ -34,7 +34,7 @@ runs:
3434
key: llvm-10.0
3535

3636
- uses: KyleMayes/install-llvm-action@v1
37-
# if: ${{ inputs.llvm == 'true' }}
37+
# if: inputs.llvm == 'true'
3838
with:
3939
version: "10.0"
4040
directory: ${{ env.LLVM_INSTALL_DIR }}

.github/composite/rust/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,8 @@ runs:
6161
cache-on-failure: true
6262

6363
- name: "Install LLVM"
64+
if: inputs.with-llvm == 'true'
6465
uses: ./.github/composite/llvm
65-
if: ${{ inputs.with-llvm == 'true' }}
6666

6767
- name: "Set environment variables used by toolchain"
6868
run: |

.github/workflows/full-ci.yml

Lines changed: 13 additions & 63 deletions
Original file line numberDiff line numberDiff line change
@@ -42,49 +42,28 @@ jobs:
4242
- name: "Install Rust"
4343
uses: ./.github/composite/rust
4444
with:
45-
rust: stable
4645
components: rustfmt
4746

4847
- name: "Check rustfmt"
4948
run: cargo fmt --all -- --check
5049

5150

5251
clippy:
53-
name: clippy (${{ matrix.name }})
5452
runs-on: ubuntu-20.04
55-
strategy:
56-
fail-fast: false
57-
matrix:
58-
include:
59-
- name: linux
60-
rust-toolchain: stable
61-
godot-binary: godot.linuxbsd.editor.dev.x86_64
62-
63-
- name: linux-double
64-
rust-toolchain: stable
65-
godot-binary: godot.linuxbsd.editor.dev.double.x86_64
66-
rust-extra-args: --features double-precision
6753
steps:
6854
- uses: actions/checkout@v3
6955

7056
- name: "Install Rust"
7157
uses: ./.github/composite/rust
72-
73-
# TODO get rid of Godot binary, once the JSON is either versioned or fetched from somewhere
74-
# Replaces also backspaces on Windows, since they cause problems in Bash
75-
- name: "Install Godot"
76-
uses: ./.github/composite/godot-install
7758
with:
78-
artifact-name: godot-${{ matrix.name }}
79-
godot-binary: ${{ matrix.godot-binary }}
59+
components: clippy
8060

8161
- name: "Check clippy"
8262
run: |
8363
cargo clippy --all-targets $GDEXT_FEATURES ${{ matrix.rust-extra-args }} -- \
8464
-D clippy::suspicious -D clippy::style -D clippy::complexity -D clippy::perf \
8565
-D clippy::dbg_macro -D clippy::todo -D clippy::unimplemented -D warnings
8666
87-
8867
unit-test:
8968
name: unit-test (${{ matrix.name }}${{ matrix.rust-special }})
9069
runs-on: ${{ matrix.os }}
@@ -98,28 +77,19 @@ jobs:
9877
include:
9978
- name: macos
10079
os: macos-11
101-
rust-toolchain: stable
102-
godot-binary: godot.macos.editor.dev.x86_64
103-
with-llvm: true
10480

10581
- name: windows
10682
os: windows-latest
107-
rust-toolchain: stable-x86_64-pc-windows-msvc
108-
godot-binary: godot.windows.editor.dev.x86_64.exe
10983

11084
# Don't use latest Ubuntu (22.04) as it breaks lots of ecosystem compatibility.
11185
# If ever moving to ubuntu-latest, need to manually install libtinfo5 for LLVM.
11286
- name: linux
11387
os: ubuntu-20.04
114-
rust-toolchain: stable
115-
godot-binary: godot.linuxbsd.editor.dev.x86_64
11688

11789
- name: linux
11890
os: ubuntu-20.04
119-
rust-toolchain: stable
12091
rust-special: -minimal-deps
121-
godot-binary: godot.linuxbsd.editor.dev.x86_64
122-
92+
12393
steps:
12494
- uses: actions/checkout@v3
12595

@@ -128,26 +98,17 @@ jobs:
12898
with:
12999
rust: stable
130100
cache-key: ${{ matrix.rust-special }} # '-minimal-deps' or empty/not defined
131-
with-llvm: ${{ matrix.with-llvm }}
132101

133102
- name: "Install Rust nightly (minimal deps)"
103+
if: matrix.rust-special == '-minimal-deps'
134104
uses: ./.github/composite/rust
135105
with:
136106
rust: nightly
137107
cache-key: minimal-deps-nightly
138-
if: ${{ matrix.rust-special == '-minimal-deps' }}
139108

140109
- name: "Install minimal dependency versions from Cargo"
110+
if: matrix.rust-special == '-minimal-deps'
141111
run: cargo +nightly update -Z minimal-versions
142-
if: ${{ matrix.rust-special == '-minimal-deps' }}
143-
144-
# TODO get rid of Godot binary, once the JSON is either versioned or fetched from somewhere
145-
# Replaces also backspaces on Windows, since they cause problems in Bash
146-
- name: "Install Godot"
147-
uses: ./.github/composite/godot-install
148-
with:
149-
artifact-name: godot-${{ matrix.name }}
150-
godot-binary: ${{ matrix.godot-binary }}
151112

152113
- name: "Compile tests"
153114
run: cargo test $GDEXT_FEATURES --no-run ${{ matrix.rust-extra-args }}
@@ -170,60 +131,49 @@ jobs:
170131
include:
171132
- name: macos
172133
os: macos-12
173-
rust-toolchain: stable
174134
godot-binary: godot.macos.editor.dev.x86_64
175-
with-llvm: true
176-
135+
177136
- name: macos-double
178137
os: macos-12
179-
rust-toolchain: stable
180138
godot-binary: godot.macos.editor.dev.double.x86_64
181139
rust-extra-args: --features double-precision
182-
with-llvm: true
183140

184-
- name: macos-bindgen
185-
artifact-name: macos
141+
- name: macos-nightly
186142
os: macos-12
187-
rust-toolchain: stable
143+
artifact-name: macos
188144
godot-binary: godot.macos.editor.dev.x86_64
189-
with-llvm: true
190145
rust-extra-args: --features godot/custom-godot
146+
with-llvm: true
191147

192148
- name: windows
193149
os: windows-latest
194-
rust-toolchain: stable-x86_64-pc-windows-msvc
195150
godot-binary: godot.windows.editor.dev.x86_64.exe
196151

197152
- name: windows-double
198153
os: windows-latest
199-
rust-toolchain: stable-x86_64-pc-windows-msvc
200154
godot-binary: godot.windows.editor.dev.double.x86_64.exe
201155
rust-extra-args: --features double-precision
202156

203-
- name: windows-bindgen
204-
artifact-name: windows
157+
- name: windows-nightly
205158
os: windows-latest
206-
rust-toolchain: stable-x86_64-pc-windows-msvc
159+
artifact-name: windows
207160
godot-binary: godot.windows.editor.dev.x86_64.exe
208161
rust-extra-args: --features godot/custom-godot
209162

210163
# Don't use latest Ubuntu (22.04) as it breaks lots of ecosystem compatibility.
211164
# If ever moving to ubuntu-latest, need to manually install libtinfo5 for LLVM.
212165
- name: linux
213166
os: ubuntu-20.04
214-
rust-toolchain: stable
215167
godot-binary: godot.linuxbsd.editor.dev.x86_64
216168

217169
- name: linux-double
218170
os: ubuntu-20.04
219-
rust-toolchain: stable
220171
godot-binary: godot.linuxbsd.editor.dev.double.x86_64
221172
rust-extra-args: --features double-precision
222173

223-
- name: linux-bindgen
224-
artifact-name: linux
174+
- name: linux-nightly
225175
os: ubuntu-20.04
226-
rust-toolchain: stable
176+
artifact-name: linux
227177
godot-binary: godot.linuxbsd.editor.dev.x86_64
228178
rust-extra-args: --features godot/custom-godot
229179

@@ -257,7 +207,7 @@ jobs:
257207
godot-binary: ${{ matrix.godot-binary }}
258208
godot-args: ${{ matrix.godot-args }}
259209
rust-extra-args: ${{ matrix.rust-extra-args }}
260-
rust-toolchain: ${{ matrix.rust-toolchain }}
210+
rust-toolchain: ${{ matrix.rust-toolchain || 'stable' }}
261211
rust-env-rustflags: ${{ matrix.rust-env-rustflags }}
262212
with-llvm: ${{ matrix.with-llvm }}
263213
godot-check-header: ${{ matrix.name == 'linux' }}

.github/workflows/minimal-ci.yml

Lines changed: 2 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -44,40 +44,21 @@ jobs:
4444

4545

4646
clippy:
47-
name: clippy (${{ matrix.name }})
4847
runs-on: ubuntu-20.04
49-
strategy:
50-
fail-fast: false
51-
matrix:
52-
include:
53-
- name: linux
54-
rust-toolchain: stable
55-
godot-binary: godot.linuxbsd.editor.dev.x86_64
56-
57-
- name: linux-double
58-
rust-toolchain: stable
59-
godot-binary: godot.linuxbsd.editor.dev.double.x86_64
60-
rust-extra-args: --features double-precision
6148
steps:
6249
- uses: actions/checkout@v3
6350

6451
- name: "Install Rust"
6552
uses: ./.github/composite/rust
66-
67-
# TODO get rid of Godot binary, once the JSON is either versioned or fetched from somewhere
68-
# Replaces also backspaces on Windows, since they cause problems in Bash
69-
- name: "Install Godot"
70-
uses: ./.github/composite/godot-install
7153
with:
72-
artifact-name: godot-${{ matrix.name }}
73-
godot-binary: ${{ matrix.godot-binary }}
54+
components: clippy
7455

7556
- name: "Check clippy"
7657
run: |
7758
cargo clippy --all-targets $GDEXT_FEATURES ${{ matrix.rust-extra-args }} -- \
7859
-D clippy::suspicious -D clippy::style -D clippy::complexity -D clippy::perf \
7960
-D clippy::dbg_macro -D clippy::todo -D clippy::unimplemented -D warnings
80-
61+
8162
8263
unit-test:
8364
name: unit-test
@@ -88,12 +69,6 @@ jobs:
8869
- name: "Install Rust"
8970
uses: ./.github/composite/rust
9071

91-
- name: "Install Godot"
92-
uses: ./.github/composite/godot-install
93-
with:
94-
artifact-name: godot-linux
95-
godot-binary: godot.linuxbsd.editor.dev.x86_64
96-
9772
- name: "Compile tests"
9873
run: cargo test $GDEXT_FEATURES --no-run
9974

@@ -113,7 +88,6 @@ jobs:
11388
with:
11489
artifact-name: godot-linux
11590
godot-binary: godot.linuxbsd.editor.dev.x86_64
116-
#godot_ver: ${{ matrix.godot }}
11791

11892

11993
license-guard:

0 commit comments

Comments
 (0)