Skip to content

Commit e4d6a8a

Browse files
authored
Documentation migration from RTD to ESP-Docs (espressif#9094)
1 parent c1a4055 commit e4d6a8a

File tree

109 files changed

+265
-194
lines changed

Some content is hidden

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

109 files changed

+265
-194
lines changed
Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,6 @@
1-
name: ReadTheDocs CI
1+
name: Documentation Build and Deploy CI
22

33
on:
4-
push:
5-
branches:
6-
- master
7-
- release/*
8-
paths:
9-
- 'docs/**'
10-
- '.github/workflows/docs.yml'
114
pull_request:
125
paths:
136
- 'docs/**'
@@ -16,7 +9,7 @@ on:
169
jobs:
1710

1811
build-docs:
19-
name: Build ReadTheDocs
12+
name: Build Documentation
2013
runs-on: ubuntu-22.04
2114
defaults:
2215
run:
@@ -34,5 +27,11 @@ jobs:
3427
sudo apt install python3-pip python3-setuptools
3528
# GitHub CI installs pip3 and setuptools outside the path.
3629
# Update the path to include them and run.
37-
PATH=/home/runner/.local/bin:$PATH pip3 install --user -r ./docs/requirements.txt
38-
cd ./docs && PATH=/home/runner/.local/bin:$PATH SPHINXOPTS="-W" make html
30+
cd ./docs
31+
PATH=/home/runner/.local/bin:$PATH pip3 install -r requirements.txt --prefer-binary
32+
PATH=/home/runner/.local/bin:$PATH SPHINXOPTS="-W" build-docs -l en
33+
- name: Archive Docs
34+
uses: actions/upload-artifact@v2
35+
with:
36+
name: docs
37+
path: docs

.github/workflows/docs_deploy.yml

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: Documentation Build and Deploy Production CI
2+
3+
on:
4+
push:
5+
branches:
6+
- release/*
7+
paths:
8+
- 'docs/**'
9+
- '.github/workflows/docs.yml'
10+
11+
jobs:
12+
13+
deploy-prod-docs:
14+
name: Deploy Documentation Production
15+
runs-on: ubuntu-22.04
16+
defaults:
17+
run:
18+
shell: bash
19+
steps:
20+
- uses: actions/checkout@v2
21+
with:
22+
submodules: true
23+
- uses: actions/setup-python@v2
24+
with:
25+
python-version: '3.10'
26+
- name: Deploy Preview
27+
env:
28+
# Deploy to production server
29+
DOCS_BUILD_DIR: "${CI_PROJECT_DIR}/docs/_build/"
30+
DOCS_DEPLOY_PRIVATEKEY: ${{ secrets.DOCS_PROD_PRIVATEKEY }}
31+
DOCS_DEPLOY_PATH: ${{ secrets.DOCS_PROD_PATH }}
32+
DOCS_DEPLOY_SERVER: ${{ secrets.DOCS_PROD_SERVER }}
33+
DOCS_DEPLOY_URL_BASE: ${{ secrets.DOCS_PROD_URL_BASE }}
34+
DOCS_DEPLOY_SERVER_USER: ${{ secrets.DOCS_PROD_USER }}
35+
run: |
36+
sudo apt update
37+
sudo apt install python3-pip python3-setuptools
38+
source ./docs/utils.sh
39+
add_doc_server_ssh_keys $DOCS_DEPLOY_PRIVATEKEY $DOCS_DEPLOY_SERVER $DOCS_DEPLOY_SERVER_USER
40+
export GIT_VER=$(git describe --always)
41+
echo "PIP install requirements..."
42+
pip3 install --user -r ./docs/requirements.txt
43+
echo "Building the Docs..."
44+
cd ./docs && build-docs -l en
45+
echo "Deploy the Docs..."
46+
deploy-docs

.github/workflows/docs_preview.yml

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: Documentation Build and Deploy CI
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
paths:
8+
- 'docs/**'
9+
- '.github/workflows/docs.yml'
10+
11+
jobs:
12+
13+
deploy-preview-docs:
14+
name: Deploy Documentation Preview
15+
runs-on: ubuntu-22.04
16+
defaults:
17+
run:
18+
shell: bash
19+
steps:
20+
- uses: actions/checkout@v3
21+
with:
22+
submodules: true
23+
- uses: actions/setup-python@v4
24+
with:
25+
python-version: '3.10'
26+
- name: Deploy Preview
27+
env:
28+
# Deploy to preview server
29+
DOCS_BUILD_DIR: "${CI_PROJECT_DIR}/docs/_build/"
30+
DOCS_DEPLOY_PRIVATEKEY: ${{ secrets.DOCS_KEY }}
31+
DOCS_DEPLOY_PATH: ${{ secrets.DOCS_PATH }}
32+
DOCS_DEPLOY_SERVER: ${{ secrets.DOCS_SERVER }}
33+
DOCS_DEPLOY_URL_BASE: ${{ secrets.DOCS_URL }}
34+
DOCS_DEPLOY_SERVER_USER: ${{ secrets.DOCS_USER }}
35+
run: |
36+
sudo apt update
37+
sudo apt install python3-pip python3-setuptools
38+
source ./docs/utils.sh
39+
add_doc_server_ssh_keys $DOCS_DEPLOY_PRIVATEKEY $DOCS_DEPLOY_SERVER $DOCS_DEPLOY_SERVER_USER
40+
export GIT_VER=$(git describe --always)
41+
echo "PIP install requirements..."
42+
pip3 install --user -r ./docs/requirements.txt
43+
echo "Building the Docs..."
44+
cd ./docs && build-docs -l en
45+
echo "Deploy the Docs..."
46+
deploy-docs

docs/Makefile

Lines changed: 0 additions & 28 deletions
This file was deleted.
File renamed without changes.

docs/_static/arduino_versions.js

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
var DOCUMENTATION_VERSIONS = {
2+
DEFAULTS: { has_targets: false,
3+
supported_targets: [ "esp32" ]
4+
},
5+
VERSIONS: [
6+
{ name: "latest", has_targets: true, supported_targets: [ "esp32", "esp32s2", "esp32s3", "esp32c3", "esp32h2", "esp32c6" ] },
7+
],
8+
IDF_TARGETS: [
9+
{ text: "ESP32", value: "esp32"},
10+
{ text: "ESP32-S2", value: "esp32s2"},
11+
{ text: "ESP32-S3", value: "esp32s3"},
12+
{ text: "ESP32-C3", value: "esp32c3"},
13+
{ text: "ESP32-H2", value: "esp32h2"},
14+
{ text: "ESP32-C6", value: "esp32c6"},
15+
]
16+
};
File renamed without changes.

0 commit comments

Comments
 (0)