lucidnz / bootstrapify-1

An open-source base theme for Shopify using Twitter Bootstrap
http://bootstrapify-theme.myshopify.com/
187 stars 72 forks source link

Error: File to import not found or unreadable: bower_components/bootstrap-sass-official/assets/stylesheets/bootstrap.scss. #233

Closed blindMoe closed 9 years ago

blindMoe commented 9 years ago

After installing a fresh copy of this app w/ no changes, when I try to run 'grunt' I am given the following error:

Running "jshint:gruntfile" (jshint) task
>> 1 file lint free.

Running "jshint:assets" (jshint) task
>> 8 files lint free.

Running "uglify:dist" (uglify) task
File theme/assets/jquery.ajax-cart.min.js created.
File theme/assets/jquery.free-shipping.min.js created.
File theme/assets/bootstrapify-option-selection.min.js created.
File theme/assets/jquery.instagram.min.js created.

Running "copy:main" (copy) task
Copied 24 files

Running "concat:dist" (concat) task
File "theme/assets/_base.js" created.

Running "concat:wufoo" (concat) task
File "theme/assets/_wufoo.scss.liquid" created.

Running "concat:styles" (concat) task
File "theme/assets/_base.scss.liquid" created.

Running "sass:dist" (sass) task
Error: File to import not found or unreadable: bower_components/bootstrap-sass-official/assets/stylesheets/bootstrap.scss.
        on line 5 of dist/scss/checkout.bootstrap.scss
        from line 2 of dist/scss/checkout.scss
  Use --trace for backtrace.
Warning: Exited with error code 65 Use --force to continue.

It looks like in dist/scss/checkout.bootstrap.scss there is:

@import "bower_components/bootstrap-sass-official/assets/stylesheets/bootstrap.scss";

But that file does not exist.

bower_components/bootstrap-sass-official/assets/stylesheets/_bootstrap.scss

does exist but it still throws the same error for some reason. I thought it may be a permissions error but just to test I chmod'ed the entire directory to 777 and it did not resolve the issue.

Please let me know what I may be missing, would love to use and contribute to Bootstrapify.

blindMoe commented 9 years ago

It looks like switching line 5 of dist/scss/checkout.bootstrap.scss to:

@import "../../bower_components/bootstrap-sass-official/assets/stylesheets/_bootstrap.scss";

fixes the issue.

galenking commented 9 years ago

Hey @blindMoe, glad you resolved it. We will see if we need to make any changes to the repo. /cc @stewartknapman

aeblin commented 8 years ago

Bumping this issue as it seems Moe's suggestion works, but the repo was never updated to include it.

For reference: This works properly:

@import "../../bower_components/bootstrap-sass-official/assets/stylesheets/_bootstrap.scss";

What's in the repo currently does not work properly.

@import "bower_components/bootstrap-sass-official/assets/stylesheets/_bootstrap.scss";
stewartknapman commented 8 years ago

Is the change needed just in /dist/scss/checkout.bootstrap.scss?

aeblin commented 8 years ago

Yep, just that one file. Once line 5 of /dist/scss/checkout.bootstrap.scss is modified to @blindMoe's fix, grunt runs without error.

stewartknapman commented 8 years ago

That should be done now

9lessons commented 7 years ago

Add this "~"

$icon-font-path: '~bootstrap-sass/assets/fonts/bootstrap/';

@import "~bootstrap-sass/assets/stylesheets/_bootstrap.scss";

sharq88 commented 7 years ago

"~" didn't work for me. however the source of the problem was a missing section from bower.json. Install section needs to be present in that file.

"install": { "path": "bower_components" },