Bower will not install packages when .bowerrc exists

I just solved this. I uninstalled and reinstalled bower, and now it works. :S

sudo npm rm -g bower

sudo npm install bower -g

Now everything works fine!


The solution here is simple :

  1. Install Bower in your public directory ( Not your app/node master directory ) For example, mynodeapp/public - npm install bower

  2. Then, set up bower from this directory : bower init

  3. Create your .bowercc file, and add to it : { "directory" : "vendor" } //Where vendor is your custom fldr

  4. Thats it. Now whenever you run a bower install command from within the public directory, it will either create or save to that "vendor" directory.

Everyone seems to have trouble because they are installing Bower outside their public folder.