You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+55-7Lines changed: 55 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -32,6 +32,16 @@ npm run start
32
32
This command starts a local development server and opens up a browser window.
33
33
Most changes are reflected live without having to restart the server (hot reload).
34
34
35
+
To run **only selected versions** (to shorten build time):
36
+
* Install `cross-env` if not already installed:
37
+
```bash
38
+
npm install -g cross-env
39
+
```
40
+
* Run:
41
+
```bash
42
+
cross-env DOCUSAURUS_VERSIONS="7.0,7.1,current" npm run start
43
+
```
44
+
35
45
## Build
36
46
37
47
```bash
@@ -46,6 +56,16 @@ Note it may be necessary to increase Node.js max memory usage, e.g. to 8 GB
46
56
$env:NODE_OPTIONS="--max-old-space-size=8192"
47
57
```
48
58
59
+
To build **only selected versions** (to shorten build time and save memory):
60
+
* Install `cross-env` if not already installed:
61
+
```bash
62
+
npm install -g cross-env
63
+
```
64
+
* Run:
65
+
```bash
66
+
cross-env DOCUSAURUS_VERSIONS="7.0,7.1,current" npm run build
67
+
```
68
+
49
69
## Serving static content
50
70
51
71
Static content can be served using a static file server, such as [serve](https://www.npmjs.com/package/serve):
@@ -60,13 +80,41 @@ The documentation is organized into two main directories
60
80
-`docs`: Contains the documentation files for latest RavenDB version.
61
81
-`versioned_docs`: Contains the documentation files for all other RavenDB versions.
62
82
63
-
## Adding new version
64
-
65
-
```bash
66
-
npm run docusaurus docs:version version_label
67
-
```
68
-
69
-
This command creates a new version of the documentation by adding `version-version_label` subdirectory to `versioned_docs` directory, which contains a snapshot of `docs` directory.
83
+
## Adding a new version
84
+
85
+
To add a new documentation version:
86
+
87
+
1. Create a snapshot of the current version in the `versioned_docs` directory.
88
+
Use:
89
+
```bash
90
+
npm run docusaurus docs:version version_label
91
+
```
92
+
2. To make the new version selectable in the sidebar, update the current version number in the `docs` property of the `docusaurus.config.js` file.
0 commit comments