Skip to content

Commit 0bf0b88

Browse files
committed
Auto merge of #12025 - jetlime:master, r=flip1995
Include GitLab in the CI section of the clippy doc book Fixes #12012 changelog: Docs: [`Continuous Integration`] now includes how to use clippy in GitLab CI.
2 parents 691d4e2 + 89e4b71 commit 0bf0b88

File tree

2 files changed

+17
-0
lines changed

2 files changed

+17
-0
lines changed

book/src/SUMMARY.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
- [Clippy's Lints](lints.md)
1010
- [Continuous Integration](continuous_integration/README.md)
1111
- [GitHub Actions](continuous_integration/github_actions.md)
12+
- [GitLab CI](continuous_integration/gitlab.md)
1213
- [Travis CI](continuous_integration/travis.md)
1314
- [Development](development/README.md)
1415
- [Basics](development/basics.md)
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# GitLab CI
2+
3+
You can add Clippy to GitLab CI by using the latest stable [rust docker image](https://hub.docker.com/_/rust),
4+
as it is shown in the `.gitlab-ci.yml` CI configuration file below,
5+
6+
```yml
7+
# Make sure CI fails on all warnings, including Clippy lints
8+
variables:
9+
RUSTFLAGS: "-Dwarnings"
10+
11+
clippy_check:
12+
image: rust:latest
13+
script:
14+
- rustup component add clippy
15+
- cargo clippy --all-targets --all-features
16+
```

0 commit comments

Comments
 (0)