Jekyll 站点仅在推送到 GitHub 时失败

Gia*_*Arb 4 ruby sass jekyll github-pages

我正在使用 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
Run Code Online (Sandbox Code Playgroud)

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

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.
Run Code Online (Sandbox Code Playgroud)

有人有任何反馈吗?非常感谢

Dav*_*uel 8

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

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

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