-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #5 from DTLab-LabCN/main
First attempt to merge modifications from DTT-Docs-stating
- Loading branch information
Showing
55 changed files
with
25,738 additions
and
481 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
#! /usr/bin/env -S bash -c 'echo "This environment file shoud be sourced, not run !" && exit 1' | ||
export DTT_DOCS_URL="https://dtlab-labcn.github.io" | ||
export ORGANIZATION_NAME='DTLab-LabCN' | ||
export PROJECT_NAME='DTT-Docs-staging' | ||
export DTT_DOCS_BASE_PATH="${PROJECT_NAME}" | ||
## Or for production docs, but you better know what you are doing | ||
# between docusaurus and github pages | ||
# export PROJECT_NAME='DTT-Docs', | ||
# export DTT_DOCS_URL="https://dtt.docs.dtlab-labcn.app" | ||
[ -z "$PS1" ] || (\ | ||
echo "The following environment variables have been set:";\ | ||
echo "DTT_DOCS_URL = $DTT_DOCS_URL";\ | ||
echo "DTT_DOCS_BASE_PATH = $DTT_DOCS_BASE_PATH";\ | ||
echo "ORGANIZATION_NAME = $ORGANIZATION_NAME";\ | ||
echo "PROJECT_NAME = $PROJECT_NAME";\ | ||
) |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
name: Deploy to GitHub Pages | ||
|
||
# Review gh actions docs if you want to further define triggers, paths, etc | ||
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#on | ||
on: | ||
push: | ||
branches: | ||
- main | ||
|
||
env: | ||
DTT_DOCS_URL: ${{ vars.DTT_DOCS_URL }} | ||
DTT_DOCS_BASE_PATH: ${{ vars.DTT_DOCS_BASE_PATH }} | ||
ORGANIZATION_NAME: ${{ github.repository_owner }} | ||
PROJECT_NAME: ${{ github.event.repository.name }} | ||
|
||
jobs: | ||
build: | ||
name: Building the documentation static web site with docusaurus | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version: 18 | ||
cache: npm | ||
|
||
- name: Install dependencies | ||
run: npm ci | ||
|
||
- name: Build website | ||
# We also create the CNAME file, this is useless in staging, | ||
# but required in production. | ||
# It is created temporarily in the static/ folder, because | ||
# docusaurus will copy it to /build | ||
run: | | ||
echo "$DTT_DOCS_URL" | cut -f 3 -d/ | tee static/CNAME | ||
npm run build | ||
- name: Upload Build Artifact | ||
uses: actions/upload-pages-artifact@v3 | ||
with: | ||
path: build | ||
|
||
deploy: | ||
name: Deploy to GitHub Pages | ||
needs: build | ||
|
||
# Grant GITHUB_TOKEN the permissions required to make a Pages deployment | ||
permissions: | ||
pages: write # to deploy to Pages | ||
id-token: write # to verify the deployment originates from an appropriate source | ||
|
||
# Deploy to the github-pages environment | ||
environment: | ||
name: github-pages | ||
url: ${{ steps.deployment.outputs.page_url }} | ||
|
||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Deploy to GitHub Pages | ||
id: deployment | ||
uses: actions/deploy-pages@v4 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
name: Test deployment | ||
# This just runs the build step, without deploying, so you know that your PR will at least build | ||
# Will it look good ? You need to deploy to know... | ||
|
||
# Review gh actions docs if you want to further define triggers, paths, etc | ||
# https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#on | ||
on: | ||
pull_request: | ||
branches: | ||
- main | ||
|
||
env: | ||
DTT_DOCS_URL: ${{ vars.DTT_DOCS_URL }} | ||
DTT_DOCS_BASE_PATH: ${{ vars.DTT_DOCS_BASE_PATH }} | ||
ORGANIZATION_NAME: ${{ github.repository_owner }} | ||
PROJECT_NAME: ${{ github.event.repository.name }} | ||
|
||
jobs: | ||
test-build: | ||
name: Test building the documentation static web site with docusaurus | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version: 18 | ||
cache: npm | ||
|
||
- name: Install dependencies | ||
run: npm ci | ||
|
||
# - name: list environment variables | ||
# run: | | ||
# env && exit 1 | ||
|
||
- name: Test build website | ||
# We also create the CNAME file, this is useless in staging, | ||
# but required in production. | ||
# It is created temporarily in the static/ folder, because | ||
# docusaurus will copy it to /build | ||
run: | | ||
echo "$DTT_DOCS_URL" | cut -f 3 -d/ | tee static/CNAME | ||
npm run build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,163 +1,20 @@ | ||
# Byte-compiled / optimized / DLL files | ||
__pycache__/ | ||
*.py[cod] | ||
*$py.class | ||
# Dependencies | ||
/node_modules | ||
|
||
# C extensions | ||
*.so | ||
# Production | ||
/build | ||
|
||
# Distribution / packaging | ||
.Python | ||
build/ | ||
develop-eggs/ | ||
dist/ | ||
downloads/ | ||
eggs/ | ||
.eggs/ | ||
lib/ | ||
lib64/ | ||
parts/ | ||
sdist/ | ||
var/ | ||
wheels/ | ||
share/python-wheels/ | ||
*.egg-info/ | ||
.installed.cfg | ||
*.egg | ||
MANIFEST | ||
# Generated files | ||
.docusaurus | ||
.cache-loader | ||
|
||
# PyInstaller | ||
# Usually these files are written by a python script from a template | ||
# before PyInstaller builds the exe, so as to inject date/other infos into it. | ||
*.manifest | ||
*.spec | ||
# Because we want to create it automatically | ||
/static/CNAME | ||
|
||
# Installer logs | ||
pip-log.txt | ||
pip-delete-this-directory.txt | ||
# Misc | ||
.DS_Store | ||
.env.local | ||
|
||
# Unit test / coverage reports | ||
htmlcov/ | ||
.tox/ | ||
.nox/ | ||
.coverage | ||
.coverage.* | ||
.cache | ||
nosetests.xml | ||
coverage.xml | ||
*.cover | ||
*.py,cover | ||
.hypothesis/ | ||
.pytest_cache/ | ||
cover/ | ||
|
||
# Translations | ||
*.mo | ||
*.pot | ||
|
||
# Django stuff: | ||
*.log | ||
local_settings.py | ||
db.sqlite3 | ||
db.sqlite3-journal | ||
|
||
# Flask stuff: | ||
instance/ | ||
.webassets-cache | ||
|
||
# Scrapy stuff: | ||
.scrapy | ||
|
||
# Sphinx documentation | ||
docs/_build/ | ||
|
||
# PyBuilder | ||
.pybuilder/ | ||
target/ | ||
|
||
# Jupyter Notebook | ||
.ipynb_checkpoints | ||
|
||
# IPython | ||
profile_default/ | ||
ipython_config.py | ||
|
||
# pyenv | ||
# For a library or package, you might want to ignore these files since the code is | ||
# intended to run in multiple environments; otherwise, check them in: | ||
# .python-version | ||
|
||
# pipenv | ||
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control. | ||
# However, in case of collaboration, if having platform-specific dependencies or dependencies | ||
# having no cross-platform support, pipenv may install dependencies that don't work, or not | ||
# install all needed dependencies. | ||
#Pipfile.lock | ||
|
||
# poetry | ||
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control. | ||
# This is especially recommended for binary packages to ensure reproducibility, and is more | ||
# commonly ignored for libraries. | ||
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control | ||
#poetry.lock | ||
|
||
# pdm | ||
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control. | ||
#pdm.lock | ||
# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it | ||
# in version control. | ||
# https://pdm.fming.dev/#use-with-ide | ||
.pdm.toml | ||
|
||
# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm | ||
__pypackages__/ | ||
|
||
# Celery stuff | ||
celerybeat-schedule | ||
celerybeat.pid | ||
|
||
# SageMath parsed files | ||
*.sage.py | ||
|
||
# Temporary sqlite database (will eventually be replaced with a real Database) | ||
test.db | ||
|
||
# Environments | ||
.env | ||
.venv | ||
env/ | ||
venv/ | ||
ENV/ | ||
env.bak/ | ||
venv.bak/ | ||
|
||
# Spyder project settings | ||
.spyderproject | ||
.spyproject | ||
|
||
# Rope project settings | ||
.ropeproject | ||
|
||
# mkdocs documentation | ||
/site | ||
|
||
# mypy | ||
.mypy_cache/ | ||
.dmypy.json | ||
dmypy.json | ||
|
||
# Pyre type checker | ||
.pyre/ | ||
|
||
# pytype static type analyzer | ||
.pytype/ | ||
|
||
# Cython debug symbols | ||
cython_debug/ | ||
|
||
# PyCharm | ||
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can | ||
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore | ||
# and can be added to the global gitignore or merged into this file. For a more nuclear | ||
# option (not recommended) you can uncomment the following to ignore the entire idea folder. | ||
#.idea/ | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.