Skip to content
This repository was archived by the owner on Aug 15, 2025. It is now read-only.

Commit fd46061

Browse files
committed
refactor: repurpose repository for openapi/typespec
1 parent 0ee471a commit fd46061

File tree

126 files changed

+25
-12020
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

126 files changed

+25
-12020
lines changed

.github/dependabot.yml

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

.github/workflows/deploy-docs-site.yml

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

.github/workflows/deploy-openapi-spec.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,17 +21,17 @@ jobs:
2121
with:
2222
node-version: "lts/*"
2323
cache: "npm"
24-
cache-dependency-path: "./api/src/core/package-lock.json"
24+
cache-dependency-path: "./src/core/package-lock.json"
2525
- name: Install TypeSpec and compile project
2626
run: |
27-
cd ./api/src/core/
27+
cd ./src/core/
2828
npm install -g @typespec/compiler
2929
npm install
3030
tsp compile .
3131
- name: Commit OpenAPI specification to repository
3232
run: |
3333
tree -L 2
34-
mv ./api/src/core/tsp-output/@typespec/openapi3/openapi.v1.0-beta.1.yaml ./api/build/core-openapi3.yaml
35-
git add ./api/build/*
34+
mv ./src/core/tsp-output/@typespec/openapi3/openapi.v1.0-beta.1.yaml ./api/build/core-openapi3.yaml
35+
git add ./build/*
3636
git commit -m "[bot]update openapi3 schema" || true
3737
git push || true

.github/workflows/python-mkdocs.yml

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

.markdownlint.json

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

.vale.ini

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

.vscode/extensions.json

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,9 @@
11
{
2-
"recommendations": [
3-
"davidanson.vscode-markdownlint",
4-
"chrischinchilla.vale-vscode",
5-
"valentjn.vscode-ltex",
6-
"gruntfuggly.todo-tree",
7-
"typespec.typespec-vscode",
8-
"bierner.markdown-mermaid",
9-
"streetsidesoftware.code-spell-checker"
10-
]
11-
}
2+
"recommendations": [
3+
"davidanson.vscode-markdownlint",
4+
"gruntfuggly.todo-tree",
5+
"typespec.typespec-vscode",
6+
"bierner.markdown-mermaid",
7+
"streetsidesoftware.code-spell-checker"
8+
]
9+
}

README.md

Lines changed: 13 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,18 @@
1-
<center>
1+
<img src="https://cloud.bitfl0wer.de/apps/files_sharing/publicpreview/2qCxoXJ27yW7QNR?file=/&fileId=1143147&x=256&y=256&a=true" align="left" alt="a purple cog, split in the middle along the horizontal axis with a gap inbetween the two halves. three overlayed, offset sinus-like waves travel through that gap. each wave has a different shade of purple" width="128px" height="auto"></img>
22

3+
### `typespec-openapi`
4+
5+
[![Code-of-conduct-shield]][Code-of-conduct]
36
[![Build/Deploy OpenAPI specification](https://github.com/polyphony-chat/docs/actions/workflows/deploy-openapi-spec.yml/badge.svg)](https://github.com/polyphony-chat/docs/actions/workflows/deploy-openapi-spec.yml)
4-
[![mkdocs documentation](https://github.com/polyphony-chat/docs/actions/workflows/python-mkdocs.yml/badge.svg)](https://github.com/polyphony-chat/docs/actions/workflows/python-mkdocs.yml)
57
[![Discord]][Discord-invite]
6-
[![Code-of-conduct-shield]][Code-of-conduct]
7-
8-
[Discord]: https://img.shields.io/badge/Discord_Server-390075
9-
[Discord-invite]: https://discord.com/invite/m3FpcapGDD
10-
[Code-of-conduct-shield]: https://img.shields.io/badge/Code_of_Conduct-eb00ff
11-
[Code-of-conduct]: https://github.com/polyphony-chat/.github/blob/main/CODE_OF_CONDUCT.md
128

13-
</center>
14-
15-
# Documentation
16-
17-
Specification documents and API documentation for the polyproto federated messaging protocol.
18-
19-
Documentation built with mkdocs-material and python3.12
9+
Specification documents and API documentation for polyproto.
2010

2111
API documentation built with [TypeSpec](https://typespec.io).
2212

2313
## Pre-compiled OpenAPI schema(s)
2414

25-
Find the pre-compiled OpenAPI schema file(s) in the [`/api/build`](https://github.com/polyphony-chat/docs/tree/main/api/build) directory. The schema is automatically built and deployed to the `main` branch on every push to the `main` branch.
26-
27-
## File structure
28-
29-
The `/docs` folder has the specification documents for the polyproto protocol.
30-
31-
The `/snippets` folder has snippets of text used in many places in the documentation. This is to ensure consistency across the documentation. Error messages appearing in many places are also stored in the `/snippets/errors` folder.
32-
33-
API documentation in form of [TypeSpec](https://typespec.io) files can be found in the `/api` directory.
34-
TypeSpec can compile to OpenAPI3, JSON Schema and Protobuf. Our TypeSpec project is targeting OpenAPI3
35-
output. Read the TypeSpec documentation for information on how to compile TypeSpec or use a pre-compiled
36-
version of the OpenAPI schema if you'd like.
15+
Find the pre-compiled OpenAPI schema file(s) in the [`/build`](https://github.com/polyphony-chat/docs/tree/main/build) directory. The schema is automatically built and deployed to the `main` branch on every push to the `main` branch.
3716

3817
## Contributing
3918

@@ -43,33 +22,22 @@ You should also read our [Code of Conduct](https://github.com/polyphony-chat/.gi
4322

4423
## Setting up a development environment
4524

46-
### Documentation
47-
48-
You will need the following things installed on your computer:
49-
50-
- `python3.12`
51-
- `pip`
52-
- Any sort of python virtual environment manager - use `venv` if in doubt
53-
- `git`
54-
55-
Optionally, you can install [`vale`](https://vale.sh/) for spell-/grammar checking.
56-
57-
Use `pip install -r requirements.txt` to install the required dependencies, and `mkdocs build` or
58-
`mkdocs serve` to build the project or serve it on localhost.
59-
60-
### API documentation
61-
6225
You will need the following things installed on your computer:
6326

6427
- `Node.js >= 20`
65-
- `npm`, `pnpm` or `yarn`
28+
- `npm` `pnpm` or `yarn`
6629
- `git`
6730
- `TypeSpec` - install it globally with `npm install -g @typespec/compiler`
6831

69-
1. Navigate to the `/api/src` directory.
32+
1. Navigate to the `/src` directory.
7033
2. Select the project you want to compile. In this example, we are compiling the `core` project.
7134
Navigate to that directory.
7235
3. Run `tsp install` to install the dependencies.
7336
4. Run `tsp compile .` to compile the project or `tsp compile --watch .` to automatically recompile
7437
the project when you save a file.
7538
5. The compiled OpenAPI3 schema will be in the `$PROJECT/tsp-output/@typespec/openapi3` directory.
39+
40+
[Discord]: https://dcbadge.vercel.app/api/server/m3FpcapGDD?style=flat
41+
[Discord-invite]: https://discord.com/invite/m3FpcapGDD
42+
[Code-of-conduct-shield]: https://img.shields.io/badge/Code_of_Conduct-eb00ff
43+
[Code-of-conduct]: https://github.com/polyphony-chat/.github/blob/main/CODE_OF_CONDUCT.md
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)