문제

My _config.yml is defined thus

# Site settings 
title: XTargets 
email: bradphelan@xtargets.com 
description: "XTargets - Technical blog of Brad Phelan" 
baseurl: "/xtargets" 
url: "http://xtargets.com" 

# Build settings 
markdown: redcarpet 
permalink: pretty 

defaults: 
  - 
    scope: 
      path: "" 
    values: 
      layout: "post" 

https://github.com/bradphelan/xtargets/blob/gh-pages/_config.yml

and when I run the jekyll server locally my posts get wrapped with the post layout. However when checked into gh-pages branch on github the pages are not wrapped.

See

http://bradphelan.github.io/xtargets/2012/03/29/simple-javascript-powered-inline-confirm/

Why would this occur?

도움이 되었습니까?

해결책

It looks like github pages has not yet updated jekyll version. pages.github.com/versions/. It's at jekyll version 1.5.1 currently.

다른 팁

This issue is not related to Front Matter defaults or GitHub Pages not running the latest Jekyll version. It's your stylesheet not being linked correctly.

Your site looks for the CSS file in http://bradphelan.github.io/css/main.css, but it is located here: http://bradphelan.github.io/xtargets/css/main.css

In head.html, change this accordingly:

<link rel="stylesheet" href="{{ "/css/main.css" | prepend: site.baseurl }}">
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top