mirror of
https://github.com/astral-sh/ruff.git
synced 2025-09-29 13:25:17 +00:00
Add exclude
support to ruff analyze
(#13425)
## Summary Closes https://github.com/astral-sh/ruff/issues/13424.
This commit is contained in:
parent
149fb2090e
commit
910fac781d
8 changed files with 108 additions and 9 deletions
|
@ -23,10 +23,10 @@ pub struct ModuleImports(BTreeSet<SystemPathBuf>);
|
|||
impl ModuleImports {
|
||||
/// Detect the [`ModuleImports`] for a given Python file.
|
||||
pub fn detect(
|
||||
db: &ModuleDb,
|
||||
path: &SystemPath,
|
||||
package: Option<&SystemPath>,
|
||||
string_imports: bool,
|
||||
db: &ModuleDb,
|
||||
) -> Result<Self> {
|
||||
// Read and parse the source code.
|
||||
let file = system_path_to_file(db, path)?;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue