我想在本地运行https://github.com/fossasia/gci18.fossasia.org/。
我用jekyll做了一次(在网站的旧版本上)并且它有效。
现在,我克隆它以便更新,但我无法让它工作。我不断收到一条错误消息
Conversion error: Jekyll::Converters::Scss encountered an error while converting 'css/style.scss':
File to import not found or unreadable: bootstrap.min. Load path: C:/Ruby25-x64/lib/ruby/gems/2.5.0/gems/jekyll-theme-primer-0.5.3/_sass on line 1
jekyll 3.7.4 | Error: File to import not found or unreadable: bootstrap.min.
Load path: C:/Ruby25-x64/lib/ruby/gems/2.5.0/gems/jekyll-theme-primer-0.5.3/_sass on line 1
我曾尝试重新安装jekyll-theme-primer,但它无法正常工作。我怎样才能解决这个问题?
根据Jekyll文档,您需要将所有SCSS部分(例如bootstrap.min.css
,themify-icon.css
和/css/style.scss
中导入的其他文件)放入/_sass/
目录以进行自动转换。
或者,您可以在import语句中指定.css
。例如:
# /css/style.scss
@import 'bootstrap.min.css';
@import 'themify-icon.css';
...
有关更多信息,请参阅https://jekyllrb.com/docs/assets/#sassscss。