简体   繁体   English

无法安装gulp-angular

[英]Cannot install gulp-angular

I am using gulp-angular for the first time, and am following this blog: http://www.angularonrails.com/how-to-wire-up-ruby-on-rails-and-angularjs-as-a-single-page-application-gulp-version/ 我第一次使用gulp-angular,并且关注此博客: http : //www.angularonrails.com/how-to-wire-up-ruby-on-rails-and-angularjs-as-a-single -page-application-gulp-version /

When I run through the install questions, it just bombs out, on Karma. 当我遇到安装问题时,它只是在Karma上被炸了。

I'm on ubuntu 14 in a Vagrant box, node v0.10.37, npm 2.7.5 我在Vagrant框中的ubuntu 14上,节点v0.10.37,npm 2.7.5

Any pointers would be greatly appreciated. 任何指针将不胜感激。

fluent@vagrant-ubuntu-trusty-64:~/fluent/client$ yo gulp-angular myapp
.
.
? Which version of Angular do you want? 1.3.x (latest)
? Which Angular's modules would you want to have? (ngRoute and ngResource will be addressed after) angular-animate.js (enable animation features),  angular-cookies.js (handle cookie management), angular-touch.js (for mobile development), angular-sanitize.js (to securely parse and manipulate HTML)
? Would you need jQuery or perhaps Zepto? None (Angular will use its own jqLite)
? Would you like to use a REST resource library? None, $http is enough!
? Would you like to use a router ? ngRoute, the official router
? Which UI framework do you want? Bootstrap, the most popular HTML, CSS, and JS framework
? How do you want to implements your Bootstrap components? Angular UI Bootstrap, Bootstrap components written in pure AngularJS by the AngularUI Team
? Which CSS preprocessor do you want? Sass (Node), Node.js binding to libsass, the C version of the popular stylesheet preprocessor, Sass.
? Which JS preprocessor do you want? None, I like to code in standard JavaScript.
? Which html template engine would you want? None, I like to code in standard HTML.
Template processing error on file karma.conf.js

events.js:72
    throw er; // Unhandled 'error' event
          ^
AssertionError: Trying to copy from a source that does not exist:     /usr/lib/node_modules/generator-gulp-angular/app/templates/karma.conf.js
at EditionInterface.exports._copySingle (/usr/lib/node_modules/generator-  gulp-angular/node_modules/yeoman-generator/node_modules/mem-fs- editor/actions/copy.js:44:3)

Some additional information, not really sure what to make of this, there is a _karma.conf.js file 一些额外的信息,真的不知道本作的是什么, 一个_karma.conf.js文件

myapp@vagrant-ubuntu-trusty-64:/usr/lib/node_modules/generator-gulp-angular/app/templates$ ls
_bower.json      e2e          gulp          _.jshintrc      _package.json         src        tslint.json
coffeelint.json  _.gitignore  _gulpfile.js  _karma.conf.js  protractor.conf.js  _tsd.json

EDIT 编辑

I have had to use sudo for all npm commands. 我必须对所有npm命令都使用sudo Is this normal? 这正常吗?

EDIT 2 https://github.com/Swiip/generator-gulp-angular/issues/470 编辑2 https://github.com/Swiip/generator-gulp-angular/issues/470

As per the github issue, deleting the reference to karma.conf.js from app/files.json did the job. 根据github问题,从app / files.json中删除对karma.conf.js的引用即可完成工作。

I guess there will be an official fix at some point. 我想这将在某个时候进行正式修复。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 将oc lazyload与gulp-angle合并 - Incorporating oc lazyload with gulp-angular 如何在gulp-Angular yeoman生成器中包含不是角度模块的依赖项? - How to include a dependency that is not an angular module in gulp-Angular yeoman generator? Yeoman gulp-angle给出错误Eacces权限被拒绝 - Yeoman gulp-angular give error Eacces Permission denied 在yeoman gulp-angular projekt设置之后的单元测试中出错 - Error in unit tests after yeoman gulp-angular projekt setup Bootstrap Nav Dropdown无法与Yeoman Gulp-Angular一起使用 - Bootstrap Nav Dropdown not working with Yeoman Gulp-Angular 用generator-ngdoc生成gulp-angular文档 - generating gulp-angular documentation with generator-ngdoc 一段时间前如何在装有gulp-angular的项目中添加Babel预处理器? - How to add the Babel preprocessor on a project scaffolded with gulp-angular some time ago? 使用回送REST API时如何更改gulp-angular项目的端口号 - How to change the port number of the gulp-angular project when using loopback REST API 我如何运行单元测试子集与Karma Gulp-Angular? - How Do I Run a Subset of Unit Tests Gulp-Angular with Karma? Gulp Connect给我无法使用Angular App获取/ - Gulp connect gives me cannot GET/ with angular app
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM