|
2 | 2 |
|
3 | 3 | use clap::{App, Arg, ArgMatches, SubCommand};
|
4 | 4 | use clippy_dev::{bless, fmt, new_lint, ra_setup, serve, stderr_length_check, update_lints};
|
5 |
| - |
6 |
| -#[cfg(feature = "lintcheck")] |
7 |
| -use clippy_dev::lintcheck; |
8 |
| - |
9 | 5 | fn main() {
|
10 | 6 | let matches = get_clap_config();
|
11 | 7 |
|
12 | 8 | match matches.subcommand() {
|
13 | 9 | ("bless", Some(matches)) => {
|
14 | 10 | bless::bless(matches.is_present("ignore-timestamp"));
|
15 | 11 | },
|
16 |
| - #[cfg(feature = "lintcheck")] |
17 |
| - ("lintcheck", Some(matches)) => { |
18 |
| - lintcheck::run(&matches); |
19 |
| - }, |
20 | 12 | ("fmt", Some(matches)) => {
|
21 | 13 | fmt::run(matches.is_present("check"), matches.is_present("verbose"));
|
22 | 14 | },
|
@@ -53,34 +45,7 @@ fn main() {
|
53 | 45 | }
|
54 | 46 |
|
55 | 47 | fn get_clap_config<'a>() -> ArgMatches<'a> {
|
56 |
| - #[cfg(feature = "lintcheck")] |
57 |
| - let lintcheck_sbcmd = SubCommand::with_name("lintcheck") |
58 |
| - .about("run clippy on a set of crates and check output") |
59 |
| - .arg( |
60 |
| - Arg::with_name("only") |
61 |
| - .takes_value(true) |
62 |
| - .value_name("CRATE") |
63 |
| - .long("only") |
64 |
| - .help("only process a single crate of the list"), |
65 |
| - ) |
66 |
| - .arg( |
67 |
| - Arg::with_name("crates-toml") |
68 |
| - .takes_value(true) |
69 |
| - .value_name("CRATES-SOURCES-TOML-PATH") |
70 |
| - .long("crates-toml") |
71 |
| - .help("set the path for a crates.toml where lintcheck should read the sources from"), |
72 |
| - ) |
73 |
| - .arg( |
74 |
| - Arg::with_name("threads") |
75 |
| - .takes_value(true) |
76 |
| - .value_name("N") |
77 |
| - .short("j") |
78 |
| - .long("jobs") |
79 |
| - .help("number of threads to use, 0 automatic choice"), |
80 |
| - ) |
81 |
| - .arg(Arg::with_name("fix").help("runs cargo clippy --fix and checks if all suggestions apply")); |
82 |
| - |
83 |
| - let app = App::new("Clippy developer tooling") |
| 48 | + App::new("Clippy developer tooling") |
84 | 49 | .subcommand(
|
85 | 50 | SubCommand::with_name("bless")
|
86 | 51 | .about("bless the test output changes")
|
@@ -197,10 +162,6 @@ fn get_clap_config<'a>() -> ArgMatches<'a> {
|
197 | 162 | .validator_os(serve::validate_port),
|
198 | 163 | )
|
199 | 164 | .arg(Arg::with_name("lint").help("Which lint's page to load initially (optional)")),
|
200 |
| - ); |
201 |
| - |
202 |
| - #[cfg(feature = "lintcheck")] |
203 |
| - let app = app.subcommand(lintcheck_sbcmd); |
204 |
| - |
205 |
| - app.get_matches() |
| 165 | + ) |
| 166 | + .get_matches() |
206 | 167 | }
|
0 commit comments