Install node. js, NPM on Linux, and build with KARMA--ANGULARJS environment

Source: Internet
Author: User
Tags install node

Installing Nodejs

    1. Build a dependent environment

    First install the g++ compiler and Git, enter the following command in the terminal

sudo apt-get install g++ Curl Libssl-dev apache2-utils
sudo apt-get install Git-core

git does not need to be installed if it is already installed .

  2. Install node. js

   Direct Input Command sudo apt-get install Nodejs installed is version 0.6, this will cause problems, resulting in the next installation of JS test tool karma, there is a problem.

So download and install the way to the official website to download http://nodejs.org

Click Install directly to download the standard version of node-v0.10.29

      

Then, execute the Install command command


CD node-v0.10.29
    ls
View within the node-v0.10.29 folder whether there is a configure this file, if not, it may not be the Standard Edition
sudo./configure errors may occur if you do not add sudo
sudo
make This step may take a while
sudo make install


  Test whether the installation was successful

   Node--version

If v0.10.29 is the version number, the installation succeeds

Installing NPM
sudo apt-get install NPM
Installing Karma
sudo npm install-g karma wait patiently

As long as the installation of Nodejs is correct, then the next two steps will be very smooth, otherwise there will be error when installing Karma

Note: Be sure to add sudo before the command, otherwise there is no permission, prone to errors

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.