Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How To Clean a Development Build of a Meteorjs App?

There are two command line programs to start/stop/manage your meteor app. There is meteor and there is mrt. As of the latest build (0.8.2 or so) it's really not clear what the difference is between these two, if any. Both seem to support the argument "help" like meteor help and mrt help. The output of both seems to be the same to me.

Sadly, I do not see a "clean" argument available when I check the help for either of these. What do I need to do if I want to achieve a clean build? One that would

  1. Blow away all packages and re-install them
  2. Blow away any compiled templates
  3. Blow away all Sass/Less compiled output

I ask this because I find myself in some kind of dependency Hades right now and want out now.

like image 458
Randy L Avatar asked May 31 '14 17:05

Randy L


People also ask

What does Meteor Reset do?

meteor resetRemoves the local mongo database. This deletes your data! Make sure you do not have any information you care about in your local mongo database by running meteor mongo . From the mongo shell, use show collections and db.

How do you make a Meteor project?

The Meteor build process is configured almost entirely through adding and removing packages to your app and putting files in specially named directories. For example, to get all of the newest stable ES2015 JavaScript features in your app, you add the ecmascript package.

How do I run a project in Meteor JS?

You can run it from the root directory of the project or from any subdirectory. Use 'meteor create ' to create a new Meteor project. Commands: run [default] Run this project in local development mode. ... run is the default in case no other command is specified after meteor .

How do I turn off Meteor command?

On OSX, go back to the term you opened to start meteor, and use CTRL + C to quit the process.


1 Answers

Meteor is still in a pre-release state. So the idea of packages is (still as of this post) not officially supported, though it will be soon. The meteor community stepped in to build their own way to use 3rd party packages and this is what meteorite does.

Most of the commands you give to meteorite are eventually passed to meteor which is why you see the same output.

The only (main difference is) mrt add which checks atmospherejs.com for packages first.

These two will be merged very soon (there is a branch on meteor on github called packaging which seeks to achieve this)

The idea of 'clean' isn't really there in meteor because most of the stuff is based on hot code reloads, so when a file changes its completely scrapped/(cleaned) and rewritten.

If you change a bit of code it will rebuild all this unless you have a syntax error.

Nonetheless if you want to 'clean' the build from everything you would have to do this in two steps (the meteor part and the meteorite part)

This erases some stuff in the hidden .meteor folder

meteor reset

Delete everything in ~/.meteorite/packages

Delete all symlinks only in your projects /packages folder. Be careful not to delete the folders because these will have been put in by you/whoever made your project and wouldn't be from atmosphere or meteor

Then run mrt update to reinstall all the atmosphere packages from scratch

like image 176
Tarang Avatar answered Dec 04 '22 05:12

Tarang