-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Clippy book #7359
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Clippy book #7359
Changes from all commits
Commits
Show all changes
19 commits
Select commit
Hold shift + click to select a range
4e6b55e
Initial commit for the Clippy Book
joshrotenberg 853d7ee
Book: add a ci chapter
joshrotenberg af38579
Move internal documentation to book
flip1995 206ec6e
Move syncing doc to book
flip1995 d6b013f
Reformat internal docs
flip1995 b374e0f
Remove Edition 2018 tests section from adding lints doc
flip1995 404432b
Book: Update GHA doc and remove GitLab placeholder
flip1995 d12a5c3
Book: Split up and rewrite installation and usage
flip1995 0e42282
Book: Write lint group descriptions
flip1995 97bceb0
Book: Restructure Dev chapter
flip1995 6b21d38
Book: Add Proposals description
flip1995 cbe4de2
Book: Add continuous integration description
flip1995 b37d24f
Move parts of CONTRIBUTING.md to the book
flip1995 c9cbead
Book: Add infrastructure description
flip1995 b551928
Auto update lint count in Clippy book
flip1995 1f11cd1
Remove bit-rotty list of Clippy team members from CONTRIBUTING.md
flip1995 9305659
Book: Improve chapter on CI
flip1995 99a731d
Book: Improve sync documentation
flip1995 b2660de
Book: Improve release documentation
flip1995 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -39,3 +39,6 @@ helper.txt | |
*.iml | ||
.vscode | ||
.idea | ||
|
||
# mdbook generated output | ||
/book/book |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
# Clippy Book | ||
|
||
This is the source for the Clippy Book. See the | ||
[book](src/infrastructure/book.md) for more information. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
[book] | ||
authors = ["The Rust Clippy Developers"] | ||
language = "en" | ||
multilingual = false | ||
src = "src" | ||
title = "Clippy Documentation" | ||
|
||
[rust] | ||
edition = "2018" | ||
|
||
[output.html] | ||
edit-url-template = "https://github.com/rust-lang/rust-clippy/edit/master/book/{path}" | ||
git-repository-url = "https://github.com/rust-lang/rust-clippy/tree/master/book" | ||
mathjax-support = true | ||
site-url = "/rust-clippy/" | ||
|
||
[output.html.playground] | ||
editable = true | ||
line-numbers = true | ||
|
||
[output.html.search] | ||
boost-hierarchy = 2 | ||
boost-paragraph = 1 | ||
boost-title = 2 | ||
expand = true | ||
heading-split-level = 2 | ||
limit-results = 20 | ||
use-boolean-and = true |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
# Clippy | ||
|
||
[](https://github.com/rust-lang/rust-clippy/actions?query=workflow%3A%22Clippy+Test%22+event%3Apush+branch%3Aauto) | ||
[](#license) | ||
|
||
A collection of lints to catch common mistakes and improve your | ||
[Rust](https://github.com/rust-lang/rust) code. | ||
|
||
[There are over 500 lints included in this crate!](https://rust-lang.github.io/rust-clippy/master/index.html) | ||
|
||
Lints are divided into categories, each with a default [lint | ||
level](https://doc.rust-lang.org/rustc/lints/levels.html). You can choose how | ||
much Clippy is supposed to ~~annoy~~ help you by changing the lint level by | ||
category. | ||
|
||
| Category | Description | Default level | | ||
| --------------------- | ----------------------------------------------------------------------------------- | ------------- | | ||
| `clippy::all` | all lints that are on by default (correctness, suspicious, style, complexity, perf) | **warn/deny** | | ||
| `clippy::correctness` | code that is outright wrong or useless | **deny** | | ||
| `clippy::suspicious` | code that is most likely wrong or useless | **warn** | | ||
| `clippy::complexity` | code that does something simple but in a complex way | **warn** | | ||
| `clippy::perf` | code that can be written to run faster | **warn** | | ||
| `clippy::style` | code that should be written in a more idiomatic way | **warn** | | ||
| `clippy::pedantic` | lints which are rather strict or might have false positives | allow | | ||
| `clippy::nursery` | new lints that are still under development | allow | | ||
| `clippy::cargo` | lints for the cargo manifest | allow | | allow | | ||
|
||
More to come, please [file an | ||
issue](https://github.com/rust-lang/rust-clippy/issues) if you have ideas! | ||
|
||
The [lint list](https://rust-lang.github.io/rust-clippy/master/index.html) also | ||
contains "restriction lints", which are for things which are usually not | ||
considered "bad", but may be useful to turn on in specific cases. These should | ||
be used very selectively, if at all. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
# Summary | ||
|
||
[Introduction](README.md) | ||
|
||
- [Installation](installation.md) | ||
- [Usage](usage.md) | ||
- [Configuration](configuration.md) | ||
- [Clippy's Lints](lints.md) | ||
- [Continuous Integration](continuous_integration/README.md) | ||
- [GitHub Actions](continuous_integration/github_actions.md) | ||
- [Travis CI](continuous_integration/travis.md) | ||
- [Development](development/README.md) | ||
- [Basics](development/basics.md) | ||
- [Adding Lints](development/adding_lints.md) | ||
- [Common Tools](development/common_tools_writing_lints.md) | ||
- [Infrastructure](development/infrastructure/README.md) | ||
- [Syncing changes between Clippy and rust-lang/rust](development/infrastructure/sync.md) | ||
- [Backporting Changes](development/infrastructure/backport.md) | ||
- [Updating the Changelog](development/infrastructure/changelog_update.md) | ||
- [Release a New Version](development/infrastructure/release.md) | ||
- [The Clippy Book](development/infrastructure/book.md) | ||
- [Proposals](development/proposals/README.md) | ||
- [Roadmap 2021](development/proposals/roadmap-2021.md) |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.