add hugo resource

This commit is contained in:
Feng Ruohang 2025-07-31 07:38:42 +08:00
parent 8f5f50977d
commit 83d41128f2
8 changed files with 248 additions and 1 deletions

2
.gitignore vendored
View File

@ -4,3 +4,5 @@ __pycache__/
.DS_Store
tmp/
output/
public/
.hugo_build.lock

11
giscus.json Normal file
View File

@ -0,0 +1,11 @@
{
"origins": [
"https://vonng.github.com/ddia",
"https://ddia.vonng.com",
"https://ddia.pgsty.com",
"http://localhost:1313"
],
"originsRegex": [
"http://localhost:[0-9]+"
]
}

5
go.mod Normal file
View File

@ -0,0 +1,5 @@
module github.com/Vonng/pg-internal
go 1.24.5
require github.com/imfing/hextra v0.9.7 // indirect

2
go.sum Normal file
View File

@ -0,0 +1,2 @@
github.com/imfing/hextra v0.9.7 h1:Zg5n24us36Bn/S/5mEUPkRW6uwE6vHHEqWSgN0bPXaM=
github.com/imfing/hextra v0.9.7/go.mod h1:cEfel3lU/bSx7lTE/+uuR4GJaphyOyiwNR3PTqFTXpI=

197
hugo.yaml Normal file
View File

@ -0,0 +1,197 @@
baseURL: 'https://ddia.vonng.com/'
languageCode: 'zh-CN'
title: '设计数据密集型应用'
enableRobotsTXT: true
# Parse Git commit
enableGitInfo: true
# enableEmoji: false
hasCJKLanguage: true
outputs:
home: [HTML]
page: [HTML]
section: [HTML, RSS]
module:
imports:
- path: github.com/imfing/hextra
defaultContentLanguage: zh
languages:
zh:
languageName: 简体中文
languageCode: zh
contentDir: content/zh
weight: 1
title: 设计数据密集型应用
tw:
languageName: 繁体中文
languageCode: tw
contentDir: content/tw
weight: 2
title: 設計資料密集型應用
en:
languageName: English
languageCode: en
contentDir: content/en
weight: 3
title: Designing Data-Intensive Applications
markup:
highlight:
noClasses: false
goldmark:
renderer:
unsafe: true
extensions:
passthrough:
delimiters:
block: [['\[', '\]'], ['$$', '$$']]
inline: [['\(', '\)']]
enable: true
menu:
main:
- name: Search
weight: 1
params:
type: search
- name: GitHub
weight: 2
url: "https://github.com/Vonng/ddia"
params:
icon: github
sidebar:
- identifier: ver
name: Version
weight: 1
params:
type: separator
- identifier: simplified-chinese
name: "简体中文 ↗"
url: "/"
weight: 2
- identifier: traditional-chinese
name: "繁體中文 ↗"
url: "/tw"
weight: 3
- identifier: english
name: "English ↗"
url: "/en"
weight: 4
- identifier: more
name: 参考链接
params:
type: separator
weight: 5
- identifier: pgint
name: "PG Internal 中文版 ↗"
url: "https://pgint.vonng.com/"
weight: 6
- identifier: pgint14
name: "PG Internal 14 中文版 ↗"
url: "https://postgres-internals.cn/"
weight: 7
- identifier: pigsty
name: "Pigsty Docs ↗"
url: "https://pgsty.com"
weight: 8
- identifier: pgext
name: "PG Extensions ↗"
url: "https://ext.pgsty.com"
weight: 9
params:
description: DDIA 中文版翻译,设计数据密集型应用是一本关于数据系统设计的书籍,作者是 Martin Kleppmann。它深入探讨了数据密集型应用的架构和设计原则涵盖了分布式系统、数据存储、消息传递等主题。
navbar:
displayTitle: true
displayLogo: true
logo:
path: /logo.png
dark: /logo.png
# width: 40
# height: 20
# link: /
width: wide
page:
# full (100%), wide (90rem), normal (80rem)
width: full
theme:
# light | dark | system
default: system
displayToggle: true
footer:
enable: true
displayCopyright: true
displayPoweredBy: false
width: normal
# Display the last modification date
displayUpdatedDate: true
dateFormat: "2006-01-02"
# Search
# flexsearch is enabled by default
search:
enable: true
type: flexsearch
flexsearch:
# index page by: content | summary | heading | title
index: content
# full | forward | reverse | strict
# https://github.com/nextapps-de/flexsearch/#tokenizer-prefix-search
tokenize: forward
editURL:
enable: true
base: "https://github.com/Vonng/ddia/edit/main/content"
toc:
displayTags: true
highlight:
copy:
enable: true
# hover | always
display: hover
comments:
enable: true
type: giscus
# https://giscus.app/
giscus:
repo: "Vonng/ddia"
repoId: "MDEwOlJlcG9zaXRvcnkxMjA3MTA2NDQ"
category: "Announcements"
categoryId: "DIC_kwDOBzHl9M4CtlWB"
mapping: pathname
strict: 0
reactionsEnabled: 1
emitMetadata: 0
inputPosition: bottom
lang: zh-CN
theme: preferred_color_scheme
# repo: imfing/hextra
# repoId: R_kgDOJ9fJag
# category: General
# categoryId: DIC_kwDOJ9fJas4CY7gW
# mapping: pathname
# strict: 0
# reactionsEnabled: 1
# emitMetadata: 0
# inputPosition: top
# lang: en
# theme: noborder_dark

14
i18n/tw.yaml Normal file
View File

@ -0,0 +1,14 @@
backToTop: "返回頂部"
changeLanguage: "切換語言"
changeTheme: "切換主題"
copyright: "© 2025 Hextra Project."
dark: "深色"
editThisPage: "在 GitHub 上編輯此頁 →"
lastUpdated: "最後更新於"
light: "淺色"
noResultsFound: "無結果"
onThisPage: "此頁上"
tags: "標籤"
poweredBy: "由 Hextra 驅動"
readMore: "更多 →"
searchPlaceholder: "搜尋文檔..."

16
i18n/zh.yaml Normal file
View File

@ -0,0 +1,16 @@
backToTop: "返回顶部"
changeLanguage: "切换语言"
changeTheme: "切换主题"
copyright: "© 2025 Hextra Project."
dark: "深色"
editThisPage: "在 GitHub 上编辑此页 →"
lastUpdated: "最后更新于"
light: "浅色"
noResultsFound: "无结果"
onThisPage: "此页上"
tags: "标签"
poweredBy: "由 Hextra 驱动"
readMore: "更多 →"
searchPlaceholder: "搜索文档..."
previous: "上一页"
next: "下一页"

BIN
static/logo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 42 KiB