adding mongo to path
Posted
by
Mike
on Super User
See other posts from Super User
or by Mike
Published on 2012-11-02T04:55:10Z
Indexed on
2012/11/02
5:11 UTC
Read the original article
Hit count: 474
Bit of a noob question. I have downloaded MongoDb and installed it here
/Users/mike/downloads/mongodb
In order to start it, I then have to 'cd' into the 'bin'
/Users/mike/downloads/mongodb/bin
and run
./mongod (to start the database)
and
./mongo (to start the mongo shell)
The problem is that I can only work with python and ruby scripts using the mongo shell if I have those scripts stored in the same bin directory, and I don't think that's the ideal set up.
Will exporting the path allow me to access mongo from outside the bin? For example, I would prefer to have my ruby scripts in /sites/ruby and be able to access mongo by starting ruby in /sites/ruby. If exporting to path is the solution, how do I do that. I'm using a mac
© Super User or respective owner