Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 28 additions & 8 deletions .github/workflows/ci-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,9 @@ on:
branches:
- main


jobs:
docs_build:
runs-on: ubuntu-20.04
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
Expand All @@ -37,22 +36,43 @@ jobs:
- name: Upload HTML Documentation
uses: actions/[email protected]
with:
name: Documentation
name: HTML-Documentation
path: doc/build/html
retention-days: 7

- name: Upload PDF Documentation
uses: actions/[email protected]
with:
name: Documentation
name: PDF-Documentation
path: doc/build/latex/*.pdf
retention-days: 7

Release:
if: github.event_name == 'push' && contains(github.ref, 'refs/tags')
needs: docs_build
runs-on: ubuntu-latest
steps:
- name: Set up Python
uses: actions/setup-python@v1
with:
python-version: 3.8

- uses: actions/download-artifact@v2

- name: Display structure of downloaded files
run: ls -R

- name: Deploy to gh-pages
uses: JamesIves/[email protected]
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
BRANCH: gh-pages
FOLDER: doc/build/html
CLEAN: true
token: ${{ secrets.github_token }}
branch: gh-pages
folder: doc/build/html
clean: true
single-commit: true

- name: Release
uses: softprops/action-gh-release@v1
with:
files: |
./**/*.pdf
55 changes: 55 additions & 0 deletions .github/workflows/nightly-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
name: Nightly Documentation Build


on:
schedule: # UTC at 0400
- cron: '0 4 * * */2' # To run every 3 days
workflow_dispatch:

jobs:
nightly_docs_build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2

- name: Setup Python
uses: actions/[email protected]
with:
python-version: 3.8

- name: Build HTML Documentation
run: |
pip install -r requirements_docs.txt --disable-pip-version-check
make -C doc html SPHINXOPTS="-W"
touch doc/build/html/.nojekyll
echo "dev.docs.pyansys.com" > doc/build/html/CNAME

- name: Build PDF Documentation
run: |
sudo apt update
sudo apt-get install -y texlive-latex-extra latexmk
make -C doc latexpdf

- name: Upload HTML Documentation
uses: actions/[email protected]
with:
name: HTML-Documentation
path: doc/build/html
retention-days: 7

- name: Upload PDF Documentation
uses: actions/[email protected]
with:
name: PDF-Documentation
path: doc/build/latex/*.pdf
retention-days: 7

- name: Deploy to gh-pages
uses: JamesIves/[email protected]
with:
token: ${{ secrets.github_token }}
branch: gh-pages
folder: doc/build/html
clean: true
single-commit: true