Skip to content

Commit 32fdf4b

Browse files
committed
fix invalid date (#73)
* fix invalid date * 404
1 parent c243080 commit 32fdf4b

File tree

3 files changed

+21
-36
lines changed

3 files changed

+21
-36
lines changed

.github/workflows/gh-pages.yml

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@ name: Deploy the website to Github Pages
33
on:
44
push:
55
branches: ["zine", "main"]
6+
pull_request:
7+
workflow_dispatch:
68

79
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
810
permissions:
@@ -20,16 +22,12 @@ concurrency:
2022
cancel-in-progress: true
2123

2224
jobs:
23-
deploy:
24-
environment:
25-
name: github-pages
26-
url: ${{ steps.deployment.outputs.page_url }}
25+
build:
2726
runs-on: ubuntu-latest
2827
steps:
2928
- uses: actions/checkout@v4
3029
with:
3130
fetch-depth: 0 # Change if you need git info
32-
3331
- name: Setup Zine
3432
uses: kristoff-it/setup-zine@v1
3533
with:
@@ -38,6 +36,14 @@ jobs:
3836
- name: Build
3937
run: zine release
4038

39+
deploy:
40+
environment:
41+
name: github-pages
42+
url: ${{ steps.deployment.outputs.page_url }}
43+
runs-on: ubuntu-latest
44+
needs: build
45+
if: github.event_name != 'pull_request'
46+
steps:
4147
- name: Setup Pages
4248
uses: actions/configure-pages@v5
4349

assets/404.html

Lines changed: 5 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -2,32 +2,14 @@
22
<html lang="en">
33
<head>
44
<meta charset="utf-8" />
5-
65
<title>404 - Page Not Found</title>
7-
8-
<!-- Custom styles for this template -->
96
<link href="/style.css" rel="stylesheet" />
10-
11-
<style>
12-
h1 {
13-
display: flex;
14-
justify-content: center;
15-
align-items: center;
16-
font-size: 3rem;
17-
}
18-
</style>
19-
20-
<script>
21-
if (location.pathname.match(/\/\d{4}\/\d{2}\/\d{2}\//)) {
22-
location.pathname = location.pathname.replace(
23-
/\/(\d{4})\/(\d{2})\/(\d{2})\//,
24-
"/$1-$2-$3-"
25-
);
26-
}
27-
</script>
287
</head>
29-
308
<body>
31-
<h1>404 - Page Not Found</h1>
9+
<center>
10+
<h1>404 - Page Not Found</h1>
11+
<p>the page you are looking for not avaible!</p>
12+
<p><a href="/">Go Home</a></p>
13+
<center>
3214
</body>
3315
</html>

content/rss.smd

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,14 @@
11
---
22
.title = "RSS Feeds Overview",
3-
.date = @date("2025-7-27"),
3+
.date = @date("2025-07-27"),
44
.author = "ZigCC",
55
.layout = "index.shtml",
66
.draft = false,
77
---
88

99
本站一共有 3 个 RSS 索引,分别索引了 学习、月刊和博客,便于满足不同读者的需求。
1010

11-
他们的链接分别是:
12-
- [/learn/index.xml]($link.page("learn").alternative('rss'))
13-
- [/monthly/index.xml]($link.page("monthly").alternative('rss'))
14-
- [/post/index.xml]($link.page("post").alternative('rss'))
15-
[/monthly/index.xml]($link.page("monthly").alternative('rss'))
16-
[/post/index.xml]($link.page("post").alternative('rss'))
17-
11+
他们的链接分别是:
12+
- [/learn/index.xml]($link.page("learn").alternative('rss'))
13+
- [/monthly/index.xml]($link.page("monthly").alternative('rss'))
14+
- [/post/index.xml]($link.page("post").alternative('rss'))

0 commit comments

Comments
 (0)