aboutsummaryrefslogtreecommitdiffhomepage
path: root/.github
diff options
context:
space:
mode:
Diffstat (limited to '.github')
-rw-r--r--.github/CONTRIBUTING.md31
-rw-r--r--.github/actions/reusable-prepare-peertube-build/action.yml10
-rw-r--r--.github/workflows/benchmark.yml2
-rw-r--r--.github/workflows/codeql/codeql-config.yml2
-rw-r--r--.github/workflows/stats.yml4
5 files changed, 30 insertions, 19 deletions
diff --git a/.github/CONTRIBUTING.md b/.github/CONTRIBUTING.md
index 80b7cba3c..16863eceb 100644
--- a/.github/CONTRIBUTING.md
+++ b/.github/CONTRIBUTING.md
@@ -53,13 +53,25 @@ interested in, user interface, design, decentralized architecture...
53You can help to write the documentation of the REST API, code, architecture, 53You can help to write the documentation of the REST API, code, architecture,
54demonstrations. 54demonstrations.
55 55
56For the REST API you can see the documentation in [/support/doc/api](https://github.com/Chocobozzz/PeerTube/tree/develop/support/doc/api) directory. 56### User documentation
57Then, you can just open the `openapi.yaml` file in a special editor like [http://editor.swagger.io/](http://editor.swagger.io/) to easily see and edit the documentation. You can also use [redoc-cli](https://github.com/Redocly/redoc/blob/master/cli/README.md) and run `redoc-cli serve --watch support/doc/api/openapi.yaml` to see the final result. 57
58The official user documentation is available on https://docs.joinpeertube.org/
59
60You can update it by writing markdown files in the following repository: https://framagit.org/framasoft/peertube/documentation/
61
62### REST API documentation
63
64The [REST API documentation](https://docs.joinpeertube.org/api-rest-reference.html) is generated from `support/doc/api/openapi.yaml` file.
65To quickly get a preview of your changes, you can generate the documentation *on the fly* using the following command:
66
67```
68npx @redocly/cli preview-docs ./support/doc/api/openapi.yaml
69```
58 70
59Some hints: 71Some hints:
60 * Routes are defined in [/server/controllers/](https://github.com/Chocobozzz/PeerTube/tree/develop/server/controllers) directory 72 * Routes are defined in [/server/server/controllers/](https://github.com/Chocobozzz/PeerTube/tree/develop/server/server/controllers) directory
61 * Parameters validators are defined in [/server/middlewares/validators](https://github.com/Chocobozzz/PeerTube/tree/develop/server/middlewares/validators) directory 73 * Parameters validators are defined in [/server/server/middlewares/validators](https://github.com/Chocobozzz/PeerTube/tree/develop/server/server/middlewares/validators) directory
62 * Models sent/received by the controllers are defined in [/shared/models](https://github.com/Chocobozzz/PeerTube/tree/develop/shared/models) directory 74 * Models sent/received by the controllers are defined in [/packages/models](https://github.com/Chocobozzz/PeerTube/tree/develop/packages/models) directory
63 75
64 76
65## Improve the website 77## Improve the website
@@ -242,15 +254,6 @@ To test emails with PeerTube:
242 * Run [mailslurper](http://mailslurper.com/) 254 * Run [mailslurper](http://mailslurper.com/)
243 * Run PeerTube using mailslurper SMTP port: `NODE_CONFIG='{ "smtp": { "hostname": "localhost", "port": 2500, "tls": false } }' NODE_ENV=dev node dist/server` 255 * Run PeerTube using mailslurper SMTP port: `NODE_CONFIG='{ "smtp": { "hostname": "localhost", "port": 2500, "tls": false } }' NODE_ENV=dev node dist/server`
244 256
245### OpenAPI documentation
246
247The [REST API documentation](https://docs.joinpeertube.org/api-rest-reference.html) is generated from `support/doc/api/openapi.yaml` file.
248To quickly get a preview of your changes, you can generate the documentation *on the fly* using the following command:
249
250```
251npx @redocly/cli preview-docs ./support/doc/api/openapi.yaml
252```
253
254### Environment variables 257### Environment variables
255 258
256PeerTube can be configured using environment variables. 259PeerTube can be configured using environment variables.
diff --git a/.github/actions/reusable-prepare-peertube-build/action.yml b/.github/actions/reusable-prepare-peertube-build/action.yml
index 03034f6cc..13e22ceb4 100644
--- a/.github/actions/reusable-prepare-peertube-build/action.yml
+++ b/.github/actions/reusable-prepare-peertube-build/action.yml
@@ -32,4 +32,12 @@ runs:
32 32
33 - name: Install peertube runner dependencies 33 - name: Install peertube runner dependencies
34 shell: bash 34 shell: bash
35 run: cd packages/peertube-runner && yarn install --frozen-lockfile 35 run: cd apps/peertube-runner && yarn install --frozen-lockfile
36
37 - name: Install peertube CLI dependencies
38 shell: bash
39 run: cd apps/peertube-cli && yarn install --frozen-lockfile
40
41 - name: Display PeerTube dependencies
42 shell: bash
43 run: ls -l node_modules/@peertube
diff --git a/.github/workflows/benchmark.yml b/.github/workflows/benchmark.yml
index ab1780c74..5f56db3ad 100644
--- a/.github/workflows/benchmark.yml
+++ b/.github/workflows/benchmark.yml
@@ -71,7 +71,7 @@ jobs:
71 71
72 - name: Run benchmark 72 - name: Run benchmark
73 run: | 73 run: |
74 node dist/scripts/benchmark.js -o benchmark.json 74 npm run benchmark-server -- -o benchmark.json
75 75
76 - name: Display result 76 - name: Display result
77 run: | 77 run: |
diff --git a/.github/workflows/codeql/codeql-config.yml b/.github/workflows/codeql/codeql-config.yml
index 8b771ae99..c96a4693e 100644
--- a/.github/workflows/codeql/codeql-config.yml
+++ b/.github/workflows/codeql/codeql-config.yml
@@ -1,4 +1,4 @@
1name: "PeerTube CodeQL config" 1name: "PeerTube CodeQL config"
2 2
3paths-ignore: 3paths-ignore:
4 - server/tests 4 - packages/tests
diff --git a/.github/workflows/stats.yml b/.github/workflows/stats.yml
index e772fdb81..573b42975 100644
--- a/.github/workflows/stats.yml
+++ b/.github/workflows/stats.yml
@@ -36,12 +36,12 @@ jobs:
36 run: | 36 run: |
37 wget "https://github.com/boyter/scc/releases/download/v3.0.0/scc-3.0.0-x86_64-unknown-linux.zip" 37 wget "https://github.com/boyter/scc/releases/download/v3.0.0/scc-3.0.0-x86_64-unknown-linux.zip"
38 unzip "scc-3.0.0-x86_64-unknown-linux.zip" 38 unzip "scc-3.0.0-x86_64-unknown-linux.zip"
39 ./scc --format=json --exclude-dir .git,node_modules,client/node_modules,client/dist,dist,yarn.lock,client/yarn.lock,client/src/locale,test1,test2,test3,client/src/assets/images,config,storage,server/tests/fixtures,support/openapi,.idea,.vscode,docker-volume,ffmpeg-3,ffmpeg-4 > ./scc.json 39 ./scc --format=json --exclude-dir .git,node_modules,client/node_modules,client/dist,dist,yarn.lock,client/yarn.lock,client/src/locale,test1,test2,test3,client/src/assets/images,config,storage,packages/tests/fixtures,support/openapi,.idea,.vscode,docker-volume,ffmpeg-3,ffmpeg-4 > ./scc.json
40 40
41 - name: PeerTube client stats 41 - name: PeerTube client stats
42 if: github.event_name != 'pull_request' 42 if: github.event_name != 'pull_request'
43 run: | 43 run: |
44 node dist/scripts/client-build-stats.js > client-build-stats.json 44 npm run client:build-stats > client-build-stats.json
45 45
46 - name: PeerTube client lighthouse report 46 - name: PeerTube client lighthouse report
47 if: github.event_name != 'pull_request' 47 if: github.event_name != 'pull_request'