如何快速开始
# 仓库
仓库地址为桌面云内网 http://gitlab.apusic.com/docs-center/docs-center.git
可以clone项目到本地
也可以直接在gitlab中修改
# 如何写文档
注意
各个产品仅维护自己的产品文件夹
下面以ALB产品为例
创建
docs/01.中间件产品/02.金蝶Apusic负载均衡器目录在
docs/01.中间件产品/02.金蝶Apusic负载均衡器目录下创建README.md图片资源存放在
docs/01.中间件产品/02.金蝶Apusic负载均衡器/assets
# 如何添加文档链接
你可以这样使用:
- 添加到导航栏
在
docs/.vuepress/config.js将该文件添加至侧边导航栏或顶部导航栏。 - 在文档中引用
- 直接访问
直接访问
http://localhost:8080/alb/test.html
# 如何配置
docs/.vuepress/config.js: 配置文件的入口文件
注意
修改了配置文件需要重新启动
# 配置顶部导航栏
nav:[ // 导航栏配置
{text: '帮助', link: '/' },
{text: '产品文档', link: '/alb/USER_GUIDE' }
]
1
2
3
4
2
3
4
# 配置侧边栏
sidebar: {
'/alb/': [
{
title: '快速开始', // 必要的
collapsable: false, // 可选的, 默认值是 true,
sidebarDepth: 1, // 可选的, 默认值是 1
children: [
'',
'test'
]
},
{
title: '帮助文档',
children: [['USER_GUIDE','用户手册'],'https','plugins'],
collapsable: false,
sidebarDepth: 1,
}
],
// fallback
'/': [
''
]
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# 启动&构建
在本地启动服务器
yarn docs:dev
1
构建静态资源包
yarn docs:build
1
构建后的资源放置在.vuepress/dist文件夹中
Jenkins流水线配置脚本路径docs-center/Jenkinsfile
设置定时每天23:00更新pdf
编辑页面 (opens new window)