温馨提示:本文翻译自stackoverflow.com,查看原文请点击:ruby - Jekyll site fails only when pushed to GitHub
ruby sass jekyll github-pages

ruby - Jekyll网站仅在推送到GitHub时失败

发布于 2020-03-27 10:57:02

我正在用Jekyll开发静态网站的新版本,并通过Github页面进行部署:https : //devcampy.com

仓库:https : //github.com/gianarb/devcampy.com

我在本地使用docker运行它,但无法重现该问题:

$ docker run --rm -p 4000:4000 -v "$PWD":/srv/jekyll jekyll/jekyll:stable jekyll serve

这是我推送到存储库时通过电子邮件收到的错误。我不知道为什么它不能正常工作

The page build failed for the `master` branch with the following error:

Your SCSS file `assets/main.scss` has an error on line 6: File to import not found or unreadable: vendor/rfs. Load paths: node_modules /hoosegow/.bundle/ruby/2.5.0/gems/jekyll-theme-primer-0.5.3/_sass /hoosegow/.bundle/ruby/2.5.0/gems/jekyll-theme-primer-0.5.3/_sass /hoosegow/.bundle/ruby/2.5.0/gems/jekyll-theme-primer-0.5.3/_sass. For more information, see https://help.github.com/en/articles/page-build-failed-invalid-sass-or-scss.

有人有反馈吗?非常感谢

查看更多

查看更多

提问者
GianArb
被浏览
97
David Jacquel 2019-07-04 16:16

您当前的引导程序代码不完整。 /node_modules/bootstrap/scss/vendor/_rfs.scss丢失,因为.gitignore规则阻止对任何供应商文件夹进行版本控制。

  1. 在您的.gitignore中,将vendorline 替换vendor/bundle

  2. 运行npm install bootstrap以覆盖当前版本