afloyd / mongo-migrate

MIT License
159 stars 81 forks source link

npm install mongo-migrate not installing mongodb #4

Closed newmanw closed 10 years ago

newmanw commented 11 years ago

Ran npm install and it did not install mongodb.

afloyd commented 10 years ago

You have to install mongodb separately from mongo-migrate... Mongo-migrate just uses mongodb libraries to querying the database

newmanw commented 10 years ago

Sure but if mongo-mongrate (npm) is dependent on mongodb (npm) then it should pull it automatically. I should not have to do npm install mongo-migrate and npm install mongodb. Your module should work out of the box by specifying the dependencies in the package.json.

You specify the mongodb dependency but as a dev dependency:

  "devDependencies": {
    "mongodb": "1.3.19"
  },

This means when I do npm install mongo-migrate, that mongodb 1.3.19 is not pulled in as a dependent module. It is dependent your module will not run without it.

Consider:

  "dependencies": {
    "mongodb": "1.3.19"
  },

You can look at other projects for examples. I.E. when I npm install mongoose I don't have to install all of its deps manually, they are pulled dynamically as they are listed in the dependencies section.

Vadorequest commented 10 years ago

That's true. Obvious, but true.

jmar777 commented 10 years ago

+1 for adding the mongodb dependency.

newmanw commented 9 years ago

Is mongodb going to be added a dependency? This really should be done.