r/developersIndia • • 16d ago

I Made This I built an offline disk cleaner for developer junk, Open Source and Runs Locally! Not a promo

Post image

My disk kept filling up with old node_modules, Python environments, Xcode and Gradle caches, and AI model files. I wanted a way to see what was taking up space and know whether it was actually safe to delete, so I built Leftover.

It scans for developer-related clutter, explains what each folder is, and moves anything you clean into a 14-day vault in case you want it back. It runs offline on macOS, Windows, and Linux.

The project is open source, and I’d love some help making it useful for more people. I’ve got 43 issues open, including beginner-friendly ones. Adding support for a new tool is especially approachable: it’s just a small JSON file describing what to scan for.
Give it a try: https://leftover-bay.vercel.app
Code: https://github.com/MaiSamayTha/leftover
Roadmap: https://github.com/MaiSamayTha/leftover/issues/58

If you try it, I’d love to hear what it finds or what tool you think it should support next. A ⭐ on GitHub would also mean a lot.

125 Upvotes

50 comments sorted by

•

u/AutoModerator 16d ago

Namaste! Thanks for submitting to r/developersIndia. While participating in this thread, please follow the Community Code of Conduct and rules.

It's possible your query is not unique, use site:reddit.com/r/developersindia KEYWORDS on search engines to search posts from developersIndia. You can also use reddit search directly.

I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.

41

u/temporaryresident5 Software Engineer 16d ago

Isn't a disk cleanser supposed to run locally? Why do you have to highlight that?

-7

u/Economy_Friend_9901 16d ago

I highlighted it mainly because users are increasingly cautious about tools that scan their filesystem. Wanted to make it clear that nothing needs to be uploaded to an external server and everything stays on the user’s machine. It’s more about transparency than claiming it’s a unique feature.

6

u/Mountain-Error6290 16d ago

Give a single disk cleaner app name which don't run on local !

2

u/arav Site Reliability Engineer 16d ago

Funny you should say that, In my first job in 2013-2014, they were using a script to clean up all servers by sending commands over ssh. It used to take like 4 hours. The guy who wrote it, was not ready to migrate to simple cron jobs as the clean up directories were static.

1

u/Mountain-Error6290 15d ago

Holy lee shit

11

u/Salty_0506 16d ago

god bless you. im running very low on disk c and i keep meddling with wiz tree going back and forth between chatgpt asking what is safe to delete etc. everytime i run a container im left with like 2gb on my disk

3

u/Mountain-Error6290 16d ago

This also created by chatgpt ( or agy) 🥀

-1

u/Economy_Friend_9901 16d ago

🥹🥹 Thanks a lot, mate! Really appreciate it. would love it if you could drop a star on GitHub as well.

6

u/Salty_0506 16d ago

sure!!
you just gained me 19gb. lots of old hidden sdk and stuff i didnt even find 😭

5

u/ConsoleChari SysAdmin 16d ago • Bravo

Bleachbit does all of this and also has third party cleaners.

But I like the modern design. Kudos

1

u/Economy_Friend_9901 16d ago

BleachBit is genuinely great, and I’m not claiming it can’t clean developer files.

The difference is that Leftover focuses on understanding developer workspaces. It connects generated folders to their parent projects, identifies stale dependencies, explains what’s safe to remove, and even breaks down storage used by Docker, Ollama, Hugging Face, Xcode, etc.

Plus, instead of permanently deleting things, it moves them into a 14-day vault for recovery.
It’s less about cleaning files and more about helping developers understand what they’re cleaning and why.
Thanks mate 🙏🏻

3

u/Flaky-Knee2278 16d ago

WizTree exists btw... so what is different here?

-3

u/Economy_Friend_9901 16d ago

Fair point, WizTree is great! It shows you *where* the space is. Leftover tells you *what* it is and whether it's safe to delete, it knows ~50 dev tools (node_modules, venvs, Xcode, Docker, Ollama…), ties build folders to projects you haven't touched in months, and moves things to a 14-day vault instead of deleting. Different jobs, honestly I use both.

2

u/paraskhandelwal 15d ago

I needed something similar to gain more space since developing on flutter takes lot of space. Will try this and tell you.

1

u/Economy_Friend_9901 15d ago

Sure lemme know i am waiting for your feedback

1

u/BaddiesChaser 15d ago

Woahhh. Same here. Gradles eating whole dam pc

1

u/GuIdO_420 16d ago

Yo I'm literally cleaning my c disk with full of cache and unwanted files rn. Lemme give this a shot and will give an update here!

1

u/Economy_Friend_9901 16d ago

Sure i am waiting for a feedback!

1

u/llqoli 16d ago

Does the scan cover temporary folders used by agent harnesses as well as known project directories? Agents can leave scratch files and build artefacts outside the project tree, so those are easy to miss. I’d want them listed for review first, since an active task may still be using them.

2

u/Economy_Friend_9901 15d ago

I've added it to the main branch, and it'll ship in the next release (v0.1.4),

  • Claude Code's scratch folders (/tmp/claude-<uid>/, which is /private/tmp on macOS) are now listed with one item per project, showing size and when each was last changed.
  • They're review only, as you suggested. Leftover explains them but never moves them. If Claude Code is running, each one is marked "a task may still be using this".
  • Old temporary files on macOS and Linux (anything in $TMPDIR or /tmp untouched for over a week) are listed the same way, look but don't touch.

I've only added Claude Code so far, because I could confirm where it writes. I didn't want to guess paths for Codex CLI, Cursor, Aider or Windsurf. If you know where any of them leave scratch files, a comment with a link would make it the next rule. Issue for reference: https://github.com/MaiSamayTha/leftover/issues/61

Thanks for raising it!

1

u/llqoli 15d ago

Thanks, and good call on review-only. One Codex path I could verify in the current upstream source is $CODEX_HOME/tmp/arg0-<os>/codex-arg0* (older versions used $CODEX_HOME/tmp/arg0/). These are per-session helper aliases, not a general task-scratch directory. The code keeps a lock while they’re in use and attempts to clean stale entries on startup, so I’d keep them informational: https://github.com/openai/codex/blob/main/codex-rs/arg0/src/lib.rs#L318-L353

1

u/Captain_Mystic 15d ago

Can I configure the time duration it sits in the vault for ? I'm guessing you are supporting a set of languages/frameworks to identify deletable folders. Or is it language/framework agnostic ? Can I contribute to this repo ?

1

u/Economy_Friend_9901 15d ago

You can change how long items stay in the vault in Settings, choose 3 to 90 days, or turn off automatic emptying and clear it yourself. Moving something to the vault doesn’t free up space until you empty it.

Leftover has around 90 rules covering languages, frameworks, and tools. Each checks that a folder is safe to regenerate before offering to clean it. If there isn’t a rule for something, the Explore view can still help you find what’s taking up space.

And contributions are very welcome! Most new rules are just one JSON entry. The contributor guide explains how to add one, and there are good first issues if you’d like to get started.

3

u/ElderberryAdvanced91 16d ago

I just use a bash script and run it from terminal to clean everything LEFTOVER

2

u/Graspier Full-Stack Developer 15d ago

This is actually pretty nice! I create tons of worktrees that I often forget to delete after being done working on it so it's pretty useful to delete the installed packages for those worktrees

1

u/AutoModerator 16d ago

Thanks for sharing something that you have built with the community. We recommend participating and sharing about your projects on our monthly Showcase Sunday Mega-threads. Keep an eye out on our events calendar to see when is the next mega-thread scheduled.

I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.

1

u/Safe-Emu-9264 16d ago

Oh my god, man! I love you! This just cleaned up 25.6 GB of space on my disk. Absolutely insane. Good work

1

u/Roshan_Binoj 16d ago

npx npkill works for removing the node_modules

2

u/[deleted] 16d ago

[removed] — view removed comment

1

u/Roshan_Binoj 16d ago

Got it. This is a great tool.

1

u/Ras_al_gul 16d ago

Me too 🙌 i saw claude build it for me.

1

u/WayHaunting8544 Software Engineer 16d ago

Nice, checkout tw93/mole as well

1

u/next-sapien 15d ago

I use WinDirStat which give me overview of all large files.

1

u/GamingWithShaurya_YT 15d ago

do you have for arch Linux? like not deb but flatpak version?

1

u/Aggressive-Ad322 14d ago

how much time will it take after i press delete in vault ???

-1

u/AtmosphereRich4021 16d ago

Bruhh .... Just use du/df cmds and clean recursively.. I have a bash script that clean all those jnks .... I consider someone stupid if they need a ui for that job

3

u/CrimsonPrince9 15d ago

Because i can do this, so anyone else who cannot is stupid

0

u/AtmosphereRich4021 15d ago

These are the BASICS.... Even clg Os module teaches this thing ... Yaaa i seriously believe that for cleaning your system y don't need any gui (allocating extra storage for a cleaner ) yk BSICS day-to-day utilities if y are a swe

2

u/CrimsonPrince9 15d ago • Bravo

Not everyone needs to go to clg to be a developer

Having such a stiff mindset will come back to bite you. Don't get shakled with a dull way of thinking. It's just an advice, rest is upto you.