Skip to content

Commit b94f9a7

Browse files
authored
Merge pull request #49 from linkwarden/dev
Dev
2 parents 3b4756a + 1506571 commit b94f9a7

18 files changed

+9091
-16648
lines changed

.github/workflows/deploy.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@ jobs:
2121

2222
- name: Install dependencies
2323
run: yarn install --frozen-lockfile
24+
- name: Generate OpenAPI docs
25+
run: yarn docusaurus gen-api-docs all
2426
- name: Build website
2527
run: yarn build
2628
- name: Deploy to GitHub Pages

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
# Generated files
88
.docusaurus
99
.cache-loader
10+
/docs/api
1011

1112
# Misc
1213
.DS_Store

README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,14 @@ $ yarn build
2424

2525
This command generates static content into the `build` directory and can be served using any static contents hosting service.
2626

27+
### Generate OpenAPI pages
28+
29+
```
30+
yarn docusaurus gen-api-docs all
31+
```
32+
33+
This command generates API docs for the OpenAPI YAML file in the `openapi` directory. The generated pages are placed in the `docs/openapi` directory.
34+
2735
### Deployment
2836

2937
Using SSH:

docs/api/_category_.json

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

docs/api/overview.md

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

docs/self-hosting/installation.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ After a few minutes (depending on your internet connection) you can access Linkw
7171

7272
:::note
7373

74-
The Manual Installation is targeted towards a more technical audience, to take an easier path, go for installation using [Docker](/self-hosting/installation#docker-).
74+
The Manual Installation is targeted towards a more technical audience, to take an easier path, go for installation using [Docker](/self-hosting/installation#docker-compose).
7575

7676
:::
7777

docs/self-hosting/upgrading/to-linkwarden-v2.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ If you did the [Manual installation](/self-hosting/installation#manual-installat
5050
node scripts/migration/migrateToV2.js
5151
```
5252

53-
For [Docker](/self-hosting/installation#docker-) users, replace `CONTAINER_ID` with your running Linkwarden container's ID and execute the following command:
53+
For [Docker](/self-hosting/installation#docker-compose) users, replace `CONTAINER_ID` with your running Linkwarden container's ID and execute the following command:
5454

5555
```
5656
docker exec -it CONTAINER_ID /bin/bash -c 'node scripts/migration/migrateToV2.js'

docs/sidebar.ts

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
// This is used to exclude the openapi sidebar item from the autogenerated sidebar
2+
// docusaurus creates so we can use the generated sidebar that docusaurus-plugin-openapi-docs creates
3+
// which automatically groups the endpoints by tag
4+
async function customSidebarItemsGenerator({
5+
defaultSidebarItemsGenerator,
6+
...args
7+
}) {
8+
const sidebarItems = await defaultSidebarItemsGenerator(args);
9+
10+
return sidebarItems.filter((item) => item.label !== "api");
11+
}
12+
13+
export default customSidebarItemsGenerator;

docusaurus.config.js

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

0 commit comments

Comments
 (0)