Fixed CI example path. #28
This file contains hidden or 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
name: Deploy Documentation Website | |
on: | |
push: | |
branches: | |
- master | |
paths: | |
- 'docs/**' | |
- 'src/**' | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
env: | |
FTP_SERVER: ${{ secrets.FTP_SERVER }} | |
FTP_USERNAME: ${{ secrets.FTP_USERNAME }} | |
FTP_PASSWORD: ${{ secrets.FTP_PASSWORD }} | |
FTP_DOCS_PATH: ${{ secrets.FTP_DOCS_PATH }} | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Set up Python 3.x | |
uses: actions/setup-python@v4 | |
with: | |
python-version: '3.x' | |
- name: Install dependencies | |
run: | | |
sudo apt-get install -y build-essential libssl-dev libxml2-dev libcurl4-openssl-dev libfontconfig1-dev zlib1g-dev libharfbuzz-dev libfribidi-dev libfreetype6-dev libpng-dev libtiff5-dev libjpeg-dev lftp | |
wget https://github.com/quarto-dev/quarto-cli/releases/download/v1.6.33/quarto-1.6.33-linux-amd64.deb | |
sudo dpkg -i quarto-1.6.33-linux-amd64.deb | |
python -m pip install --upgrade pip | |
python -m pip install build itables jupyter myst-parser setuptools sphinx sphinx-autodoc-typehints | |
- name: Build Sphinx docs | |
run: | | |
python -m build | |
python -m pip install dist/$(basename `ls -Art dist | tail -n 1` -py3-none-any.whl).tar.gz | |
cd docs | |
make html | |
- name: Deploy documentation via FTP | |
env: | |
FTP_PASSWORD: ${{ secrets.FTP_PASSWORD }} | |
run: | | |
lftp -c " | |
set ssl:verify-certificate no; | |
open -u $FTP_USERNAME,$FTP_PASSWORD $FTP_SERVER; | |
mirror -R -P 5 ./docs/build/html $FTP_DOCS_PATH; | |
bye; | |
" |