Book Image

Node Web Development - Second Edition

By : David Herron
Book Image

Node Web Development - Second Edition

By: David Herron

Overview of this book

Table of Contents (17 chapters)
Node Web Development Second Edition
Credits
About the Author
Acknowledgement
About the Reviewers
www.PacktPub.com
Preface
Index

Installing Node using package managers


The preferred method for installing Node, now, is to use the versions available in package managers such as apt-get, or MacPorts. Package managers simplify your life by helping to maintain the current version of the software on your computer and ensuring to update dependent packages as necessary, all by typing a simple command such as apt-get update. Let's go over this first.

Installing on Mac OS X with MacPorts

The MacPorts project (http://www.macports.org/) has for years been packaging a long list of open source software packages for Mac OS X, and they have packaged Node. After you have installed MacPorts using the installer on their website, installing Node is pretty much this simple:

$ sudo port search nodejs
nodejs @0.10.6 (devel, net)
    Evented I/O for V8 JavaScript

nodejs-devel @0.11.2 (devel, net)
    Evented I/O for V8 JavaScript

Found 2 ports.
--
npm @1.2.21 (devel)
    node package manager
$ sudo port install nodejs npm
.. long log of downloading...