Kruftle compared to kondo and npkill
The honest version, including where the other two are the better choice. If anything here misrepresents either project, open an issue and it gets fixed.
rm -rf with a prompt.”
That is a legitimate design, and it is why kondo is faster than Kruftle. It is also
the one thing Kruftle deliberately does not do.
The actual difference
Kruftle works out what a project is built with and runs that toolchain’s
own clean command — cargo clean, flutter clean,
./gradlew clean. cargo clean knows which files in
target/ belong to Cargo. A shell glob matching the name
target does not.
This matters in three specific cases:
- The name is a coincidence. A
target/in a non-Rust project, abuild/that is a source directory, adist/someone committed on purpose. - Git is tracking it. Some repositories commit their build output deliberately, because the build is not reproducible on every machine. A rebuild will not bring that back. Kruftle excludes anything git tracks from the default selection — this needs git installed to check, and it cannot restrain a toolchain’s own clean command, only Kruftle’s own raw deletion.
- There is a symlink in the way. A
node_modulespointing at a shared directory on another volume. Kruftle never follows one and never deletes through one.
Side by side
| Kruftle | kondo | npkill | |
|---|---|---|---|
| How it removes artifacts | Runs the toolchain’s own clean command | Deletes the directory | Deletes the directory |
| Stacks detected | 42, built in | 20+, built in | node_modules by default — any name via -t |
| Interface | Desktop GUI | CLI and GUI | Interactive CLI |
| Platforms | macOS, Windows, Linux | macOS, Windows, Linux | Anywhere Node runs |
| Needs the SDK installed | Yes, for the proper clean | No | No |
| Speed | Slower | Fast | Fast |
| Space reclaimed | Slightly less — clean commands keep some reusable caches | More | More |
| Skips anything git tracks | Yes | No | No |
| Follows symlinks | Never | Optional | — |
| Dry run with a real measurement | Yes | — | — |
| Add a new project type without a PR | Yes — cleanup profiles | No | Yes — via -t, name only |
| Filter by last-modified age | No | Yes | Yes |
| Licence | GPL-3.0 | MIT | MIT |
Where the other tools are better
kondo is faster, and it does not need your SDKs. Running
cargo clean means starting Cargo, which takes real time across a
hundred crates, and it only works if Cargo is installed. kondo deletes the
directory either way. If you are cleaning an archive disk full of projects whose
toolchains you no longer have, kondo is the better fit. Its age filter —
only projects untouched in three months — is genuinely useful and Kruftle
has no equivalent.
kondo has a CLI. Kruftle does not, yet. If you want this in a shell script or a scheduled job outside the app, kondo works today. Kruftle’s core is pure Dart with no Flutter imports specifically so a CLI can exist, but it is not written.
npkill is excellent at the one thing it is built for. If your
problem is node_modules specifically, npkill is a smaller download,
faster to reach for, and needs no install beyond npx.
Kruftle reclaims slightly less space, on purpose. Clean commands
keep caches a rebuild can reuse. cargo clean leaves things behind
that deleting target/ outright would not. That is usually what you
want, and the report says when the real figure came in under the dry-run estimate
and by how much.
Where Kruftle is better
- Nested projects. The Rust crate inside a Flutter app has
build output that
flutter cleanwill never touch, and it is often where the gigabytes actually are. Kruftle finds projects inside projects. - You see it before it happens. A dry run with a real measurement, a treemap of where the space actually is, and a per-project checklist.
- Raw deletion is a fallback, not the mechanism. It happens only when the SDK is genuinely absent, the directory name is on that stack’s own allow-list, and you have ticked a box for that run.
- The rails cannot be waived. Kruftle refuses
/, your home directory and system paths outright, with no override. Each of the ten rails has a test that fails closed. - A missing stack is a form, not a fork. A cleanup profile teaches Kruftle a project type in the app itself — name, markers, clean command, artifact directories — with the same safety rails as a built-in stack.
- It reports what was really freed, not what it predicted.
Which should you use
Your problem is node_modules specifically → npkill.
You want a CLI, maximum speed, or you are cleaning projects whose toolchains are gone → kondo.
You want to see what will happen before it happens, across many languages, and you would rather the toolchain decide what is safe to delete → Kruftle.
Find out what your disk is actually holding
A scan changes nothing. You may be surprised by the number.