cargo-cache
cargo-cache copied to clipboard
How did you find out about cargo-cache?
Hi, if you read this and use cargo cache
, please let me know how you found out about this project and leave a comment on this ticket. :)
I am curious to know!
I wanted to completely clear my cargo cache. I searched for cargo clear cache
and this repo was one of the top results (using Duck Duck Go).
Just learned about this on Twitter now and will be trying this out today: https://twitter.com/DappForce/status/1183111484911566848?s=09
I noticed cargo search --help
suggests --offline
might do something useful and figured it would inspect the cache. Turns out it doesn't (see also: https://github.com/rust-lang/cargo/issues/1506).
$ cargo search --offline -- nom
error: can't make HTTP request in the offline mode
After some manual poking around in my ~/.cargo/registry/cache/
I searched the web for cargo search cache
and found a link to this project on crates.io.
$ cargo install cargo-cache
$ cargo cache query nom
Registry cache sorted by name:
nom-4.2.3: 115343
nom-5.0.1: 128602
Registry source cache sorted by name:
nom-4.2.3: 656802
nom-5.0.1: 788878
It works! Thanks.
I was actually looking for something different, a global cache for cargo builds across different projects ... But this also sounds very useful thanks :)
You might be looking for sccache.
Star from Jon!

Thanks!
Also just found this twitter thread mentioning it: https://twitter.com/nick_r_cameron/status/1237481127129960448
Explained in https://github.com/matthiaskrgr/cargo-cache/issues/76#issuecomment-629653999 (while advocating for a new feature).
Had the same exact idea. Was gonna be my toy project. Now I'll need to find something new! hehehe. Nice job with this crate!
Found it on the issue tracker: https://github.com/rust-lang/cargo/issues/3289
I found this issue itself through the link generated from @SirWindfield's comment above 😁
My company has some Rust shared libraries hosted on a private Git server. I set up a launchd agent on macOS to add my identity to ssh-agent and wanted to make sure it was working. I was looking for a way to clear out downloaded Git repos that were cached so I could try again from a clean state. cargo-cache worked great!
Seen it mentioned in Rust's Matrix channel, immediately installed :smiley:
Found it via your comment in via rust-lang/cargo#3289
Hi Matthias,
I found about your cargo cache
when low on disk space on my GIT/Rust partition :).
The source was some article about purging the cargo cache, and/or about cleaning up when cargo artifacts/cache is sick. Either way, thank you.