Skip to content

Commit 5bc3fa6

Browse files
committed
initial vitepress conversion
1 parent 4e108a3 commit 5bc3fa6

23 files changed

+6991
-3160
lines changed

docs.Dockerfile

Lines changed: 0 additions & 26 deletions
This file was deleted.

docs/.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
node_modules
2+
*/public/
3+
.vitepress/cache

docs/.vitepress/config.js

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
import baseConfig from '@cakephp/docs-skeleton/config'
2+
3+
import { createRequire } from "module";
4+
const require = createRequire(import.meta.url);
5+
const toc_en = require("./toc_en.json");
6+
7+
const versions = {
8+
text: "5.x",
9+
items: [
10+
{ text: "5.x (latest)", link: "https://book.cakephp.org/5.x/", target: '_self' },
11+
{ text: "4.x", link: "https://book.cakephp.org/migrations/4/en/", target: '_self' },
12+
{ text: "3.x", link: "https://book.cakephp.org/migrations/3/en/", target: '_self' },
13+
{ text: "2.x", link: "https://book.cakephp.org/migrations/2/en/", target: '_self' },
14+
],
15+
};
16+
17+
// This file contains overrides for .vitepress/config.js
18+
export default {
19+
extends: baseConfig,
20+
srcDir: 'en',
21+
title: 'Migrations plugin',
22+
description: 'Migrations - CakePHP migrations Documentation',
23+
base: "/5.x/",
24+
rewrites: {
25+
"en/:slug*": ":slug*",
26+
},
27+
sitemap: {
28+
hostname: "https://book.cakephp.org/migrations/5.x/",
29+
},
30+
themeConfig: {
31+
socialLinks: [
32+
{ icon: "github", link: "https://github.com/cakephp/cakephp" },
33+
],
34+
editLink: {
35+
pattern: "https://github.com/cakephp/migrations/edit/5.x/docs/:path",
36+
text: "Edit this page on GitHub",
37+
},
38+
sidebar: toc_en,
39+
nav: [
40+
{ text: "CakePHP Book", link: "https://book.cakephp.org/" },
41+
{ ...versions },
42+
],
43+
},
44+
substitutions: {
45+
'|phpversion|': { value: '8.5', format: 'bold' },
46+
'|minphpversion|': { value: '8.2', format: 'italic' },
47+
'|cakeversion|': '5.3',
48+
'|cakefullversion|': 'CakePHP 5',
49+
},
50+
locales: {
51+
root: {
52+
label: "English",
53+
lang: "en",
54+
},
55+
},
56+
};

docs/.vitepress/theme/index.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
export { default } from '@cakephp/docs-skeleton'

docs/.vitepress/toc_en.json

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
{
2+
"/": [
3+
{
4+
"text": "Migrations",
5+
"collapsed": false,
6+
"items": [
7+
{ "text": "Introduction", "link": "/index" },
8+
{ "text": "Writing Migrations", "link": "/writing-migrations" },
9+
{ "text": "Using the Query Builder", "link": "/using-the-query-builder" },
10+
{ "text": "Executing Queries", "link": "/executing-queries" },
11+
{ "text": "Database Seeding", "link": "/seeding" }
12+
]
13+
},
14+
{
15+
"text": "Upgrade Guides",
16+
"collapsed": true,
17+
"items": [
18+
{ "text": "Upgrading from 4.x to 5.x", "link": "/upgrading" },
19+
{ "text": "Upgrading to the Builtin Backend", "link": "/upgrading-to-builtin-backend" }
20+
]
21+
}
22+
]
23+
}

docs/config/__init__.py

Whitespace-only changes.

docs/config/all.py

Lines changed: 0 additions & 53 deletions
This file was deleted.

docs/en/conf.py

Lines changed: 0 additions & 9 deletions
This file was deleted.

docs/en/contents.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
### CakePHP Migrations
2+
3+
- [Migrations 5.x](index)
4+
- [Writing Migrations](writing-migrations)
5+
- [Using the Query Builder](using-the-query-builder)
6+
- [Executing Queries](executing-queries)
7+
- [Database Seeding](seeding)
8+
- [Upgrading to the builtin backend](upgrading-to-builtin-backend)

docs/en/contents.rst

Lines changed: 0 additions & 10 deletions
This file was deleted.

0 commit comments

Comments
 (0)