📝 测试文档部署

This commit is contained in:
2024-08-28 11:38:46 +08:00
parent 8ba6ee805a
commit f6e73dd3be
18 changed files with 159 additions and 8 deletions

View File

@ -4,6 +4,16 @@ import { defineConfig } from 'vitepress'
export default defineConfig({
title: "MBCP docs",
description: "MBCP library docs",
locales: {
root: {
label: '简体中文',
lang: 'zh-CN'
},
en: {
label: 'English',
lang: 'en-US'
}
},
themeConfig: {
// https://vitepress.dev/reference/default-theme-config
nav: [
@ -22,7 +32,8 @@ export default defineConfig({
],
socialLinks: [
{ icon: 'github', link: 'https://github.com/vuejs/vitepress' }
{ icon: 'github', link: 'https://github.com/snowykami/mbcp' }
]
}
},
srcDir: '.'
})

View File

@ -0,0 +1,13 @@
import {defineConfig, type DefaultTheme} from 'vitepress'
export const common = defineConfig({
title: "MBCP docs",
description: "MBCP library docs",
themeConfig: {
// https://vitepress.dev/reference/default-theme-config
socialLinks: [
{icon: 'github', link: 'https://github.com/snowykami/mbcp'}
]
},
srcDir: '.'
})

View File

@ -0,0 +1,10 @@
import {defineConfig, type DefaultTheme} from 'vitepress'
export const en = defineConfig({
lang: "en-US",
description: "A library made for Minecraft particle generation",
themeConfig: {
},
})

View File

@ -0,0 +1,15 @@
import {defineConfig} from "vitepress";
import {common} from './common'
import {en} from './en'
import {zh} from './zh'
export default defineConfig({
...common,
locales:{
root: { label: "简体中文", ...zh },
en: { label: "English", ...en }
}
})

View File

@ -0,0 +1,10 @@
import {defineConfig, type DefaultTheme} from 'vitepress'
export const zh = defineConfig({
lang: "zh-Hans",
description: "一个用于Minecraft粒子计算和生成的库",
themeConfig: {
},
})

View File

@ -3,5 +3,4 @@ title: mbcp.\n\ninit\n\n
order: 1
icon: laptop-code
category: API
---
---

View File

@ -9,10 +9,10 @@ hero:
actions:
- theme: brand
text: 快速开始
link: /guide
link: md-ex
- theme: alt
text: API
link: api
text: API文档
link: api/
features:
- title: 高可用性

View File

@ -301,7 +301,7 @@ def generate_docs(module_folder: str, output_dir: str, with_top: bool = False, l
os.mkdir(output_dir)
replace_data = {
"__init__": "indedx",
"__init__": "index",
".py" : ".md",
}