The last couple days I have been struggling with installing Ionic 2 on my Windows 10 laptop.
Here is my Ionic info:
C:\Dev\ionicProjects>ionic info
Your system information:
Cordova CLI: 6.3.1
Gulp version: CLI version 3.9.0
Gulp local:
Ionic CLI Version: 2.1.0
Ionic App Lib Version: 2.1.0-beta.1
OS:
Node Version: v6.7.0
Here is the error I was getting when trying to start a project. Really helpful, right?
C:\Dev\ionicProjects>ionic start –v2 myApp
Creating Ionic app in folder C:\Dev\ionicProjects\myApp based on tabs project
Downloading: https://github.com/driftyco/ionic2-app-base/archive/master.zip
[=============================] 100% 0.0s
Downloading: https://github.com/driftyco/ionic2-starter-tabs/archive/master.zip
[=============================] 100% 0.0s
Installing npm packages…
Error with start undefined
Error Initializing app: There was an error with the spawned command: npminstall
There was an error with the spawned command: npminstall
Caught exception:
undefined
Mind letting us know? https://github.com/driftyco/ionic-cli/issues
So I struggled trying many different things and finally figured out that I needed to install git which is needed for running ionic start.
SOLUTION: Download and install git from here
https://git-for-windows.github.io/
Then restart your command prompt and hopefully it work just as it did for me…
i have already install git ,how to solve it ,thank you so much
Did you try uninstalling and reinstalling Ionic? Are you on the latest version of Node.js? Can you let me know what “ionic info” returns as well as the error you see?