I am not sure if this has been discussed before, but having been playing/developing with meteor for almost 2 years, my $HOME/.meteor folder holds a lot of outdated “stuff”.
Recently I decided to blow away my .meteor folder and install it from scratch. Unfortunately, when entering and old project directory and just issuing meteor --version it downloads the meteor tool for that old version before even displaying it, loading my .meteor directory with cruft again.
What is the recommended way to clean out versions of meteor/packages no longer desired from the .meteor folder?
Meteor has to download the appropriate version of the command line tool to run an old app. You can check what version an app is using without downloading the tool by reading the .meteor/release file directly.
I was looking for being able to selectively remove old meteor versions. Reinstalling seems like such a heavy handed approach, albeit in today’s high-speed internet world this might not be that bad.
The other problem is that when running meteor update it downloads the .meteor/release version first
Hmm, that’s kind of awkward. We haven’t been optimizing for disk space so far, but we could be a lot more cautious about downloading extra stuff when it isn’t needed. This will be particularly helpful for people with small hard drives and slow internet connections. You should report this as a feature request on GitHub! https://github.com/meteor/meteor/issues
I just wrote a small node program to allow to delete all the files belonging to a certain release. I put it in a gist. The script itself only prints the rm commands to stdout.
I am running a VirtualMachine with ony 20GB disk space (which I thought would be big enough). My meteor-tool directory is 8GB and I would like to reduce this size. Any way to do this?
Look into deleting your .meteor/local/bundler-cache directory and contents. See:
(EDIT: Just noticed you mentioned meteor-tools specifically, so this won’t help. Still, worth mentioning as that linker directory grows quite large over time…)
For clarity, the ~/.meteor folder and the .meteor folder are in two seperate locations - the latter being the .meteor folder that exists in my project.
is there a way to make meteor-tool… or, well, anything meteor related to Verify package hashes and re-download the partially downloaded ones?
i’ve encountered this problem a couple of times recently… when meteor-tool starts to download packages… but something breaks during the process and then i start getting really weird errors like files missing on import (even if they are part of the project and lay directly next to the file that is importing it)
it just happened with the recent meteor 1.3.3 … i ran a project and meteor said that there is 1.3.3 version available and it is downloading it… but, well, i had to restart the application (i’m in development mode now) to re-read some ENV_VARs. And, well,… it fails to start now as meteor-tool was just partially unpacked/installed but it got a chance to replace the path to the new tool in ~/.meteor/meteor.bat
as a side note - updating meteor-tool takes painfully long time on windows machine like an hour or something