forked from oneapi-src/oneMKL
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
github actions workflow for publishing documentation (oneapi-src#494)
Co-authored-by: Dai-Ni Hsieh <dai-ni.hsieh@intel.com>
- Loading branch information
1 parent
7c3eec6
commit 90bc218
Showing
4 changed files
with
108 additions
and
213 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,60 @@ | ||
name: Documentation | ||
permissions: read-all | ||
|
||
# Trigger for PR or merge to develop branch | ||
on: | ||
push: | ||
branches: develop | ||
paths: | ||
- 'docs/**' | ||
pull_request: | ||
paths: | ||
- 'docs/**' | ||
workflow_dispatch: | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 | ||
- uses: actions/setup-python@82c7e631bb3cdc910f68e0081d67478d79c6982d # v5.1.0 | ||
with: | ||
python-version: '3.11' | ||
cache: 'pip' | ||
- name: Install Dependencies | ||
run: pip install -r docs/requirements.txt | ||
- name: Configure & Build | ||
run: | | ||
cmake -DCMAKE_VERBOSE_MAKEFILE=on -B build docs | ||
cmake --build build | ||
- uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808 # v4.3.3 | ||
with: | ||
name: docs | ||
path: build/Documentation/html | ||
|
||
publish: | ||
needs: build | ||
if: github.event_name == 'workflow_dispatch' || github.event_name == 'push' && github.ref == 'refs/heads/develop' | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write | ||
steps: | ||
- uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 | ||
with: | ||
ref: gh-pages | ||
path: gh-pages | ||
- name: Remove old site | ||
run: rm -rf gh-pages/* | ||
- uses: actions/download-artifact@65a9edc5881444af0b9093a5e628f2fe47ea3b2e # v4.1.7 | ||
with: | ||
name: docs | ||
path: gh-pages | ||
- name: Push to GitHub Pages | ||
run: | | ||
cd gh-pages | ||
touch .nojekyll | ||
git add . | ||
git config --global user.name "GitHub Actions" | ||
git config --global user.email github-actions@github.com | ||
git commit -m "Update documentation" | ||
git push --force origin gh-pages |
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
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,28 @@ | ||
accessible-pygments==0.0.5 | ||
alabaster==0.7.16 | ||
Babel==2.15.0 | ||
beautifulsoup4==4.12.3 | ||
certifi==2024.2.2 | ||
charset-normalizer==3.3.2 | ||
docutils==0.21.2 | ||
idna==3.7 | ||
imagesize==1.4.1 | ||
Jinja2==3.1.4 | ||
MarkupSafe==2.1.5 | ||
packaging==24.0 | ||
pydata-sphinx-theme==0.15.2 | ||
Pygments==2.18.0 | ||
requests==2.32.1 | ||
snowballstemmer==2.2.0 | ||
soupsieve==2.5 | ||
Sphinx==7.3.7 | ||
sphinx-book-theme==1.1.2 | ||
sphinxcontrib-applehelp==1.0.8 | ||
sphinxcontrib-devhelp==1.0.6 | ||
sphinxcontrib-htmlhelp==2.0.5 | ||
sphinxcontrib-jsmath==1.0.1 | ||
sphinxcontrib-qthelp==1.0.7 | ||
sphinxcontrib-serializinghtml==1.1.10 | ||
tomli==2.0.1 | ||
typing_extensions==4.11.0 | ||
urllib3==2.2.1 |