four digit year #3 + README update

This commit is contained in:
Niko Abeler 2022-08-13 19:15:34 +02:00
parent e15268092a
commit c89bca3fc7
2 changed files with 2 additions and 1 deletions

View File

@ -45,6 +45,7 @@ Posts are Markdown files with a mandatory metadata head.
```
---
title: My new Post
date: 13 Aug 22 17:07 UTC
aliases:
- /my/new/post
- /old_blog_path/

View File

@ -100,7 +100,7 @@ func (user User) CreateNewPost(title string) (Post, error) {
initial_content := ""
initial_content += "---\n"
initial_content += "title: " + title + "\n"
initial_content += "date: " + time.Now().UTC().Format(time.RFC822) + "\n"
initial_content += "date: " + time.Now().UTC().Format("02 Jan 2006 15:04 MST") + "\n"
initial_content += "---\n"
initial_content += "\n"
initial_content += "Write your post here.\n"