-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix the timezone cause post can't be showed
- Loading branch information
XuPengfei
committed
Dec 22, 2023
1 parent
8409a83
commit 1a3bd49
Showing
3 changed files
with
42 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
_site | ||
.DS_Store | ||
.jekyll | ||
.jekyll-metadata | ||
.bundle | ||
.sass-cache | ||
Gemfile.lock | ||
node_modules | ||
package.json | ||
*.gem | ||
*.gemspec | ||
.jekyll-cache | ||
.jekyll-metadata | ||
vendor |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
--- | ||
date: 2023-12-22 22:19:43 | ||
date: 2023-12-22 22:19:43 +0800 | ||
layout: post | ||
title: 重新整理了一下 | ||
categories: 文章 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
--- | ||
date: 2023-12-22 22:29:43 +0800 | ||
layout: post | ||
title: Jekyll因为时区问题无法显示文章的解决办法 | ||
categories: Tips | ||
tags: 新奇好玩 | ||
--- | ||
|
||
刚写好的文章push到GitHub上无法显示,Google了一下发现是因为时区的问题导致新提交的文章没有被编译。 | ||
|
||
解决的办法如下: | ||
|
||
1、在_config.yml中添加时区设定 | ||
|
||
``` | ||
timezone: Asia/Shanghai | ||
``` | ||
|
||
2、在文章头部的时间戳位置添加 +0800 | ||
|
||
``` | ||
date: 2023-12-22 22:29:43 +0800 | ||
``` | ||
|
||
参考链接: | ||
|
||
<https://changwh.github.io/2019/03/17/timezone-issue-in-jekyll/> |