jekyll帖子不能在github页面上正确显示/格式化(其余网站是OK的) [英] jekyll posts not displaying/formatting correctly on github pages (rest of site is OK though)

查看:315
本文介绍了jekyll帖子不能在github页面上正确显示/格式化(其余网站是OK的)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我最终设法让这个网站在线时,我感到非常高兴,但不幸的是,这些帖子没有正确设置格式和样式,我不知道问题是什么。它位于 https://github.com/skydusk/skydusk.github.io 和该网站在这里: http://skydusk.github.io/



任何人都可以告诉我我在这里做错了什么?

config.yml

##网站标题
名称:skydusk
url:http:// skydusk。 github.io
##降价处理器
markdown:kramdown
##语法高亮显示器。将其更改为pygments
highlighter:pygments

## define base_url在sitemap.xml和robots.txt中的有效用法
base_url:/ skydusk
sass:
sass_dir:_sass
style::compressed
paginate:5
paginate_path:page:num
##网站描述(用于meta标签)
简介:只是另一个个人博客
##您网站上的一些常用关键字
关键字:windows,storage,crashplan,synology,备份,itunes

##定义此对于disqus评论支持
#disqus:skydusk

##设置此为启用谷歌分析
#ga_id:UA-66844898-1
#ga_domain:www.skydusk .com

##一些常用链接
链接:
脸书:用户名
twitter:用户名
电子邮件:info@skydusk.com
github:用户名

##在img /目录中放置所需的图像并相应地设置该值。如果未定义,则将使用占位符图像。
about_image:placeholder.jpg
## comment这个如果你想要没有边栏的全角文章
sidebar:off


解决方案

问题出在default.html中。
< link rel =stylesheethref =css / style.css> 必须更改为

 < link rel =stylesheethref =/ css / style.css> 

这是由于nowonmai666在reddit上引起的, 。我希望这可以帮助别人。


I was quite happy when I finally managed to get this site online, but unfortunately the posts don't format or style correctly and I don't know what the problem is. Its located at https://github.com/skydusk/skydusk.github.io and the site is here: http://skydusk.github.io/

Can anyone tell me what i've done wrong here?

config.yml

##The website title
name: skydusk
url: "http://skydusk.github.io"
##Markdown processor
markdown: kramdown
##syntax highlighter. change it to pygments
highlighter: pygments

##define base_url for valid usage in sitemap.xml and robots.txt
base_url: /skydusk
sass:
  sass_dir: _sass
  style: :compressed
paginate: 5
paginate_path: "page:num"
##The website description (to be used in meta tags)
description: just another personal blog
##Some frequently used keywords on your website
keywords: windows, storage, crashplan, synology, backups, itunes

##define this for disqus comment support
#disqus: skydusk

##set this to enable google analytics
#ga_id: UA-66844898-1
#ga_domain: www.skydusk.com

##Some commonly used links
links:
  facebook: username
  twitter: username
  email: info@skydusk.com
  github: username

##put desired image in img/ directory and set the value accordingly. If not defined, a placeholder image will be used.
about_image: placeholder.jpg
##comment this if you want full width posts with no sidebar
sidebar: off

解决方案

the problem was in default.html. <link rel="stylesheet" href="css/style.css"> had to be changed to

<link rel="stylesheet" href="/css/style.css"> 

It was the lack of a dash at the start that was causing it, thanks to nowonmai666 over on reddit. I hope this can help someone.

这篇关于jekyll帖子不能在github页面上正确显示/格式化(其余网站是OK的)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆