Skip to content

Commit e8cebbe

Browse files
committed
ci: lint Rust code
1 parent c232a58 commit e8cebbe

File tree

6 files changed

+33
-0
lines changed

6 files changed

+33
-0
lines changed

.github/workflows/build.yml

+8
Original file line numberDiff line numberDiff line change
@@ -351,6 +351,10 @@ jobs:
351351
export LSAN_OPTIONS="suppressions=${GITHUB_WORKSPACE}/.lsan_suppressions"
352352
meson test -C build
353353
354+
- name: Lint Rust
355+
run: |
356+
ninja -C build clippy
357+
354358
- name: Print meson test log
355359
if: ${{ failure() && steps.tests.outcome == 'failure' }}
356360
run: |
@@ -609,6 +613,10 @@ jobs:
609613
run: |
610614
meson test -C build
611615
616+
- name: Lint Rust
617+
run: |
618+
ninja -C build clippy
619+
612620
- name: Print meson test log
613621
if: ${{ failure() && steps.tests.outcome == 'failure' }}
614622
run: |

subprojects/packagefiles/isolang/meson.build

+5
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,16 @@ project(
55
license: 'Apache-2.0',
66
)
77

8+
rust_args = [
9+
'-Aclippy::all',
10+
]
11+
812
lib = static_library(
913
'isolang',
1014
'src/lib.rs',
1115
override_options: ['rust_std=2021', 'build.rust_std=2021'],
1216
rust_abi: 'rust',
17+
rust_args: rust_args,
1318
dependencies: dependency('phf', fallback: ['phf', 'phf_dep']),
1419
)
1520

subprojects/packagefiles/language-tags/meson.build

+5
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,16 @@ project(
55
license: 'MIT OR Apache-2.0',
66
)
77

8+
rust_args = [
9+
'-Aclippy::all',
10+
]
11+
812
lib = static_library(
913
'language_tags',
1014
'src/lib.rs',
1115
override_options: ['rust_std=2021', 'build.rust_std=2021'],
1216
rust_abi: 'rust',
17+
rust_args: rust_args,
1318
)
1419

1520
language_tags_dep = declare_dependency(

subprojects/packagefiles/phf/meson.build

+5
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,16 @@ project(
55
license: 'MIT',
66
)
77

8+
rust_args = [
9+
'-Aclippy::all',
10+
]
11+
812
lib = static_library(
913
'phf',
1014
'src/lib.rs',
1115
override_options: ['rust_std=2021', 'build.rust_std=2021'],
1216
rust_abi: 'rust',
17+
rust_args: rust_args,
1318
dependencies: dependency('phf_shared', fallback: ['phf_shared', 'phf_shared_dep']),
1419
)
1520

subprojects/packagefiles/phf_shared/meson.build

+5
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,16 @@ project(
55
license: 'MIT',
66
)
77

8+
rust_args = [
9+
'-Aclippy::all',
10+
]
11+
812
lib = static_library(
913
'phf_shared',
1014
'src/lib.rs',
1115
override_options: ['rust_std=2021', 'build.rust_std=2021'],
1216
rust_abi: 'rust',
17+
rust_args: rust_args,
1318
dependencies: dependency('siphasher', fallback: ['siphasher', 'siphasher_dep']),
1419
)
1520

subprojects/packagefiles/siphasher/meson.build

+5
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,16 @@ project(
55
license: 'MIT OR Apache-2.0',
66
)
77

8+
rust_args = [
9+
'-Aclippy::all',
10+
]
11+
812
lib = static_library(
913
'siphasher',
1014
'src/lib.rs',
1115
override_options: ['rust_std=2021', 'build.rust_std=2021'],
1216
rust_abi: 'rust',
17+
rust_args: rust_args,
1318
)
1419

1520
siphasher_dep = declare_dependency(

0 commit comments

Comments
 (0)