Search code examples
angularjsnpmbower-install

npm-install throws exception for angular-seed


I am trying to install and configure angular-seed in my webstorm IDE. After creating project and downloading angular-seed i tried to run npm install command to install all the dependencies like the page says (https://github.com/angular/angular-seed). But i found the following error when trying to run the command. the error is given bellow:

bower angular-route#~1.4.0      ENOGIT git is not installed or not in the PATH

npm ERR! Windows_NT 6.3.9600
npm ERR! argv "C:\\Program Files\\nodejs\\\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install"
npm ERR! node v0.12.5
npm ERR! npm  v2.11.2
npm ERR! code ELIFECYCLE
npm ERR! [email protected] postinstall: `bower install`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] postinstall script 'bower install'.
npm ERR! This is most likely a problem with the angular-seed package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     bower install
npm ERR! You can get their info via:
npm ERR!     npm owner ls angular-seed
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!     C:\Users\User\WebstormProjects\untitled\npm-debug.log

I tried to install bower first by running the command npm install -g bower and then running another command bower install angular but it does not working either. It shows another error:

bower angular#~1.4.0            ENOGIT git is not installed or not in the PATH

Can anyone help me to find the solution of the problem. Please let me know where i have done wrong.


Solution

  • Do you have installed git? If you run cmd.exe and write

    git
    

    what do you see? If is git installed correctly in global path, you see git help.

    If git is installed only as Git Bash, you can run bower in Git Bash.

    Alternatively you can (re)install git with this option, then will be git available in command promt (global path)

    enter image description here