scotch / angular-brunch-seed

AngularJS + Brunch
Other
228 stars 78 forks source link

NO_BOWER_JSON #82

Closed tolyo closed 3 years ago

tolyo commented 10 years ago

I am getting the following error when trying to build a project:

error: { [Error: Component must have "/Applications/angularbrunch/bower_components/console-polyfill/bower.json"] code: 'NO_BOWER_JSON' }

The bower install step does not seem to be working either.

Toly

kylefinley commented 10 years ago

What version of bower --version are you using?

If you use the bundle version of bower i.e. ./node_modules/.bin/bower --version should be 1.0.0.

Also, you might try removing the bower_components directory and reinstalling.

rm -rf bower_components
./node_modules/.bin/bower install

Please let me know if any of that helps

tolyo commented 10 years ago

@kylefinley

I am not seeing bower_components directory. Bower version is 1.0.3. brunch build is running fine with angular-brunch-seed-modularized fork, which does not have bower_components directory either.

Tolyo

kylefinley commented 10 years ago

Brunch now has native bower support. The newest version of bower creates a bower_components directory. angular-brunch-seed-modularized isn't using the latest version of brunch / bower that's why there isn't a bower_components directory.

If you are working off of an old repo you might have an .bowerrc file that sets the bower directory to vendor. Try deleting the file and running bower install

If that doesn't work, I think the easiest way to get things working would be:

git clone https://github.com/scotch/angular-brunch-seed.git
cd angular-brunch-seed
./script/init.sh

If that still doesn't work then maybe a bug was introduced with a recent version of bower, because I've tested this recently and it was working.

tolyo commented 10 years ago

The old repo build is working fine. I guess I will revert to that for now. But this is what I m currently getting with the latest build: 02 Aug 11:59:44 - error: { [Error: Component must have "/angular-brunch-seed/bower_components/console-polyfill/bower.json"] code: 'NO_BOWER_JSON' } 02 Aug 11:59:44 - error: Compiling of 'app/styles/app.less' failed. '/bower_components/bootstrap-less/less/reset.less' wasn't found.

es128 commented 10 years ago

@tolyo see if you have a .bowerrc in the project directory or any of its parent directories. If so, it will redirect where the bower components get installed to and cause this error.

tolyo commented 10 years ago

@es128

Italics were key - I am back to living my life on the edge. Thank you!

Cheers Toly