为什么我安装bootstrap时会报错呢?
D:\Mooc>bower install bootstrap
bower ENOGIT git is not installed or not in the PATH
D:\Mooc>
为什么我安装bootstrap时会报错呢?
D:\Mooc>bower install bootstrap
bower ENOGIT git is not installed or not in the PATH
D:\Mooc>
2014-08-27
我知道了,因为npm中install的git和所需要的不是同一个,大家需要去 http://msysgit.github.io/下载Git-1.9.4-preview20140815.exe安装包,安装后才可以。如果安装后仍然不行,需要重新设定Path环境变量,将安装后的bin目录加到Path中,然后在执行bower install bootstrap就可以了。
D:\Mooc>npm uninstall git
unbuild git@0.1.5
D:\Mooc>bower install bootstrap
bower ENOGIT git is not installed or not in the PATH
(下载/安装 Git-1.9.4-preview20140815.exe )
D:\Mooc>PATH=%PATH%;C:\Program Files (x86)\Git\bin;
D:\Mooc>bower install bootstrap
bower not-cached git://github.com/twbs/bootstrap.git#*
bower resolve git://github.com/twbs/bootstrap.git#*
bower download https://github.com/twbs/bootstrap/archive/v3.2.0.tar.gz
bower extract bootstrap#* archive.tar.gz
bower resolved git://github.com/twbs/bootstrap.git#3.2.0
bower not-cached git://github.com/jquery/jquery.git#>= 1.9.0
bower resolve git://github.com/jquery/jquery.git#>= 1.9.0
bower download https://github.com/jquery/jquery/archive/2.1.1.tar.gz
bower extract jquery#>= 1.9.0 archive.tar.gz
bower resolved git://github.com/jquery/jquery.git#2.1.1
bower install bootstrap#3.2.0
bower install jquery#2.1.1
bootstrap#3.2.0 bower_components\bootstrap
└── jquery#2.1.1
jquery#2.1.1 bower_components\jquery
D:\Mooc>
举报