Help
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Pilot Lvl 1
Message 1 of 5

Add Front Matter - GitHub Pages tutorial doesn't work

Solved! Go to Solution.

Hello.

 

I am currently on the "Add Front Matter" activity, however, it does not work. For some reason, even although I do have 

---
title: "Your blog post title"
date:  YYYY-MM-DD
---

it says that I don't. Pictures are attached.bot doesn't work.pngconfig.png 

4 Replies
Solution
Moderator
Message 2 of 5

Re: Add Front Matter - GitHub Pages tutorial doesn't work

Hey @yangciou! Sorry if this wasn't clear - you have the right front matter (the text between the --- lines, including those --- lines), but its in the wrong file. Moving those lines over to the start of your other file _posts/2018-05-28-Hello.md should do the trick.

 

Let me know if that works!

Pilot Lvl 1
Message 3 of 5

Re: Add Front Matter - GitHub Pages tutorial doesn't work

Yeah, that was the problem. Thank you, I fixed it now.

 

It wasn't clear, because it said

  1. Click the "Files Changed" tab in this pull request

  2. Click on the pencil icon on the right side of the screen

  3. Add the following content to the top of your blog post:

 

so I assumed to click the pencil for the first file, not the second.

 

There is also a bug, the date is bolded for some reason as shown in the picture, and the bot doesn't consider that right, but when I put a line in between, the bold is gone and it works again.bolded date.pngnot bolded.png

Moderator
Message 4 of 5

Re: Add Front Matter - GitHub Pages tutorial doesn't work

Great, glad to hear that that worked!

 

The bolded date isn't really a bug, but I can see why that'd be confusing. Markdown has multiple ways to set text as bold, and one of them is to put dashes on the line below some text. The text renderer on GitHub isn't sure that the text you're writing is front matter, so it looks bold in the editor.

 

Have a great day!

Copilot Lvl 2
Message 5 of 5

Re: Add Front Matter - GitHub Pages tutorial doesn't work

I was having the same issue. Thank God I re-read it and caught the word 'blog'. Before that I had the problem of 'review required'. I had to delete the repo like 4 time. Managed it the 5th time. Phew.