Split off ruff_cli crate from ruff library

This lets you test the ruff linters or use the ruff library
without having to compile the ~100 additional dependencies
that are needed by the CLI.

Because we set the following in the [workspace] section of Cargo.toml:

   default-members = [".", "ruff_cli"]

`cargo run` still runs the CLI and `cargo test` still tests
the code in src/ as well as the code in the new ruff_cli crate.
(But you can now also run `cargo test -p ruff` to only test the linters.)
This commit is contained in:
Martin Fischer 2023-01-12 13:10:33 +01:00 committed by Charlie Marsh
parent 403a004e03
commit 82aff5f9ec
27 changed files with 330 additions and 282 deletions

View file

@ -2,7 +2,7 @@
use anyhow::Result;
use clap::{Args, CommandFactory};
use ruff::cli::Cli as MainCli;
use ruff_cli::Cli as MainCli;
use crate::utils::replace_readme_section;