Skip to content
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

--ignored-dirs argument ignores the project itself #93

Closed
orhun opened this issue Jul 5, 2023 · 3 comments
Closed

--ignored-dirs argument ignores the project itself #93

orhun opened this issue Jul 5, 2023 · 3 comments

Comments

@orhun
Copy link
Contributor

orhun commented Jul 5, 2023

I'm not sure if this is the expected behavior but I came across this issue while I was working on #92

To reproduce:

$ cargo new repro
$ cargo build
# target directory is created
$ kondo
Projects cleaned: 0, Bytes deleted: 0.0B
# nothing is cleaned

I think this is due to:

kondo/kondo/src/main.rs

Lines 57 to 61 in 51828a1

fn prepare_directories(dirs: Vec<PathBuf>) -> Result<Vec<PathBuf>, Box<dyn Error>> {
let cd = current_dir()?;
if dirs.is_empty() {
return Ok(vec![cd]);
}

might be regression in #90

@tbillington
Copy link
Owner

Oh yep, I see what's happening, nice catch.

@tbillington
Copy link
Owner

Should be fixed in a48eb09. Please let me know if there was still any issues :)

@orhun
Copy link
Contributor Author

orhun commented Jul 5, 2023

Works fine now, thank you for the fix!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants