You are on page 1of 2

Add to the PATH on Mac OS X 10.

8 Mountain Lion - Ryan Hoffman

28/03/13 18:57

Add to the PATH on Mac OS X 10.8 Mountain Lion


October 02, 2012 I just bought a neat Mac Mini! Im using it to do some MonoTouch and Mono for Android development! In the process of setting everything up, I installed node.js. After the node.js installer finished, it recommended to add /usr/local/share/npm/bin to my path. It turns out there is a very neat way to do this in OS X, the /etc/paths file! The file contains a list (one per line) of paths that are added to the $PATH variable in the shell. Here are some quick directions to add to the path: Open up Terminal. Run the following command: Enter your password, when prompted. Go to the bottom of the file, and enter the path you wish to add. Hit control-x to quit. Enter Y to save the modified buffer. Thats it! To test it, in new terminal window, type: You should see something similar to this (including the path youve added!):
1 MacMini:~ ryan$ echo $PATH 2 /usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/local/share/npm/bin

Here is a screenshot of what my file looks like:

http://architectryan.com/2012/10/02/add-to-the-path-on-mac-os-x-mountain-lion/#.UVS8M78usy7

Pgina 1 de 2

Add to the PATH on Mac OS X 10.8 Mountain Lion - Ryan Hoffman

28/03/13 18:57

Posted by Ryan Hoffman October 02, 2012 Mac OS X Mountain Lion (10.8), Terminal From SQL Server to MongoDB Remap Home and End on OS X 10.8 Mountain Lion

http://architectryan.com/2012/10/02/add-to-the-path-on-mac-os-x-mountain-lion/#.UVS8M78usy7

Pgina 2 de 2

You might also like