0

I'm making my first steps with AngularJS , and I try to create a project using Yeoman. I installed yeoman, bower, grunt, angular-generator . But I get the following error when I use the command grunt after using yo angular myApp :

Running "wiredep:app" (wiredep) task Warning: Error: Cannot find where you keep your Bower packages. Use --force to continue.

After some researches I found that I should edit my Gruntfile.js file to change the cwd parameter, but I couldn't understand how.

yo doctor tells me that everything is fine with Yeoman.

I am using Windows 10, I tried to run it in a virtual machine with Ubuntu 16.04, and got the exact same error :(

Tell me if you need more details !

Dot31
  • 11
  • 2
  • Can u check where directory is pointed to in .bowerrc file { "directory": "app/components" } – Srikanth Nov 30 '16 at 22:27
  • { "directory": "bower_components"} is the only line I got in my .bowerrc file. Should I create a bower_components directory at the root of my project ? – Dot31 Nov 30 '16 at 22:29
  • Make sure all the module "dependencies" you defined in bower.json file are at directory pointed by "directory" in .bowerrc – Srikanth Nov 30 '16 at 22:31
  • In my case I have all modules under app/components, so I edited it to { "directory": "app/components" } in .bowerrc file – Srikanth Nov 30 '16 at 22:32
  • Did you try executing `npm install` and `bower install`? – VincenzoC Nov 30 '16 at 22:33
  • Yes executing above cmds will install(get) all the required modules under the required directory. Try that first. – Srikanth Nov 30 '16 at 22:35
  • @VincenzoC When running `npm install` I got : npm WARN enoent ENOENT: no such file or directory, open 'A:\Programmation\Angular\test-yeoman\node_modules\bower_components\package.json' And when running `bower install` : bower angular-animate#^1.4.0 ENOGIT git is not installed or not in the PATH . @Srikanth Should I edit the `"appPath": "app",` line ? – Dot31 Nov 30 '16 at 22:40
  • No need to edit appPath. You should be using either npm or bower to install angular dependencies initailly. Refer to this link https://github.com/angular/bower-angular – Srikanth Nov 30 '16 at 22:50
  • Thanks I'm reading it. Will edit this post when I find the solution. Thank you guys :) – Dot31 Nov 30 '16 at 22:52
  • This link will give you more details.https://www.sitepoint.com/kickstart-your-angularjs-development-with-yeoman-grunt-and-bower/ – Srikanth Nov 30 '16 at 22:54
  • please check this [Error: Cannot find where you keep your Bower packages. Use --force to continue](http://stackoverflow.com/questions/31578794/error-cannot-find-where-you-keep-your-bower-packages-use-force-to-continue) – gopigoppu Jan 17 '17 at 05:41

0 Answers0