Skip to content

Commit 27dc565

Browse files
committed
cargo dev: rename ra-setup to ra_setup to be in line with the other commands
1 parent 91fa25c commit 27dc565

File tree

5 files changed

+10
-10
lines changed

5 files changed

+10
-10
lines changed

CONTRIBUTING.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,10 @@ All contributors are expected to follow the [Rust Code of Conduct].
1919
- [Writing code](#writing-code)
2020
- [Getting code-completion for rustc internals to work](#getting-code-completion-for-rustc-internals-to-work)
2121
- [How Clippy works](#how-clippy-works)
22-
- [Fixing build failures caused by Rust](#fixing-build-failures-caused-by-rust)
22+
- [Syncing changes between Clippy and [`rust-lang/rust`]](#syncing-changes-between-clippy-and-rust-langrust)
2323
- [Patching git-subtree to work with big repos](#patching-git-subtree-to-work-with-big-repos)
24-
- [Performing the sync](#performing-the-sync)
25-
- [Syncing back changes in Clippy to [`rust-lang/rust`]](#syncing-back-changes-in-clippy-to-rust-langrust)
24+
- [Performing the sync from [`rust-lang/rust`] to Clippy](#performing-the-sync-from-rust-langrust-to-clippy)
25+
- [Performing the sync from Clippy to [`rust-lang/rust`]](#performing-the-sync-from-clippy-to-rust-langrust)
2626
- [Defining remotes](#defining-remotes)
2727
- [Issue and PR triage](#issue-and-pr-triage)
2828
- [Bors and Homu](#bors-and-homu)
@@ -111,7 +111,7 @@ To work around this, you need to have a copy of the [rustc-repo][rustc_repo] ava
111111
`git clone https://github.com/rust-lang/rust/`.
112112
Then you can run a `cargo dev` command to automatically make Clippy use the rustc-repo via path-dependencies
113113
which rust-analyzer will be able to understand.
114-
Run `cargo dev ra-setup --repo-path <repo-path>` where `<repo-path>` is an absolute path to the rustc repo
114+
Run `cargo dev ra_setup --repo-path <repo-path>` where `<repo-path>` is an absolute path to the rustc repo
115115
you just cloned.
116116
The command will add path-dependencies pointing towards rustc-crates inside the rustc repo to
117117
Clippys `Cargo.toml`s and should allow rust-analyzer to understand most of the types that Clippy uses.

clippy_dev/src/fmt.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ pub fn run(check: bool, verbose: bool) {
8989
},
9090
CliError::RaSetupActive => {
9191
eprintln!(
92-
"error: a local rustc repo is enabled as path dependency via `cargo dev ra-setup`.
92+
"error: a local rustc repo is enabled as path dependency via `cargo dev ra_setup`.
9393
Not formatting because that would format the local repo as well!
9494
Please revert the changes to Cargo.tomls first."
9595
);

clippy_dev/src/main.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ fn main() {
3535
("limit_stderr_length", _) => {
3636
stderr_length_check::check();
3737
},
38-
("ra-setup", Some(matches)) => ra_setup::run(matches.value_of("rustc-repo-path")),
38+
("ra_setup", Some(matches)) => ra_setup::run(matches.value_of("rustc-repo-path")),
3939
("serve", Some(matches)) => {
4040
let port = matches.value_of("port").unwrap().parse().unwrap();
4141
let lint = matches.value_of("lint");
@@ -131,7 +131,7 @@ fn get_clap_config<'a>() -> ArgMatches<'a> {
131131
.about("Ensures that stderr files do not grow longer than a certain amount of lines."),
132132
)
133133
.subcommand(
134-
SubCommand::with_name("ra-setup")
134+
SubCommand::with_name("ra_setup")
135135
.about("Alter dependencies so rust-analyzer can find rustc internals")
136136
.arg(
137137
Arg::with_name("rustc-repo-path")

clippy_dev/src/ra_setup.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ fn inject_deps_into_manifest(
5252
// do not inject deps if we have aleady done so
5353
if cargo_toml.contains("[target.'cfg(NOT_A_PLATFORM)'.dependencies]") {
5454
eprintln!(
55-
"cargo dev ra-setup: warning: deps already found inside {}, doing nothing.",
55+
"cargo dev ra_setup: warning: deps already found inside {}, doing nothing.",
5656
manifest_path
5757
);
5858
return Ok(());

doc/basics.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ the codebase take a look at [Adding Lints] or [Common Tools].
88
[Common Tools]: https://github.com/rust-lang/rust-clippy/blob/master/doc/common_tools_writing_lints.md
99

1010
- [Basics for hacking on Clippy](#basics-for-hacking-on-clippy)
11-
- [Get the code](#get-the-code)
11+
- [Get the Code](#get-the-code)
1212
- [Building and Testing](#building-and-testing)
1313
- [`cargo dev`](#cargo-dev)
1414
- [PR](#pr)
@@ -87,7 +87,7 @@ cargo dev update_lints
8787
# create a new lint and register it
8888
cargo dev new_lint
8989
# (experimental) Setup Clippy to work with rust-analyzer
90-
cargo dev ra-setup
90+
cargo dev ra_setup
9191
```
9292

9393
## PR

0 commit comments

Comments
 (0)