-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Co-authored-by: Roberto Pastor Muela <[email protected]>
- Loading branch information
Showing
5 changed files
with
31 additions
and
40 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 |
---|---|---|
|
@@ -20,10 +20,10 @@ env: | |
PYMAPDL_START_INSTANCE: FALSE | ||
PYMAPDL_PORT: 21000 # default won't work on GitHub runners | ||
PYMAPDL_DB_PORT: 21001 # default won't work on GitHub runners | ||
RESET_PIP_CACHE: 0 | ||
RESET_AUTOSUMMARY_CACHE: 0 | ||
RESET_EXAMPLES_CACHE: 0 | ||
RESET_DOC_BUILD_CACHE: 0 | ||
RESET_PIP_CACHE: 0 | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
|
@@ -45,14 +45,14 @@ jobs: | |
name: "Documentation Style Check" | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: PyAnsys documentation style checks | ||
- name: "PyAnsys documentation style checks" | ||
uses: ansys/actions/doc-style@v5 | ||
with: | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
|
||
smoke-tests: | ||
name: Build and Smoke tests | ||
name: "Build and Smoke tests" | ||
runs-on: ${{ matrix.os }} | ||
needs: [code-style] | ||
strategy: | ||
|
@@ -69,7 +69,7 @@ jobs: | |
- should-release: false | ||
os: windows-latest | ||
steps: | ||
- name: Build wheelhouse and perform smoke test | ||
- name: "Build wheelhouse and perform smoke test" | ||
uses: ansys/actions/build-wheelhouse@v5 | ||
with: | ||
library-name: ${{ env.PACKAGE_NAME }} | ||
|
@@ -107,7 +107,7 @@ jobs: | |
restore-keys: | | ||
Python-v${{ env.RESET_PIP_CACHE }}-${{ runner.os }}-${{ matrix.mapdl-version }} | ||
- name: Install ansys-mapdl-core | ||
- name: "Install ansys-mapdl-core" | ||
run: | | ||
python -m pip install ansys-mapdl-core | ||
|
@@ -149,7 +149,7 @@ jobs: | |
name: ${{ matrix.mapdl-version }}-remote.xml | ||
flags: remote,${{ matrix.mapdl-version }} | ||
|
||
- name: Upload coverage artifacts | ||
- name: "Upload coverage artifacts" | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: ${{ matrix.mapdl-version }}-remote.xml | ||
|
@@ -214,15 +214,16 @@ jobs: | |
doc-build: | ||
name: Doc building | ||
name: "Doc building" | ||
runs-on: ubuntu-latest | ||
needs: [doc-style] | ||
outputs: | ||
ANSYSMATH_VERSION: ${{ steps.version.outputs.ANSYSMATH_VERSION }} | ||
env: | ||
PYMAPDL_PORT: 21000 # default won't work on GitHub runners | ||
PYMAPDL_DB_PORT: 21001 # default won't work on GitHub runners | ||
PYMAPDL_START_INSTANCE: FALSE | ||
steps: | ||
# This checkout is repeated later at the 'doc-build' action. This could be avoided by copything the sh file here, but introduces some code duplicity. | ||
- name: "Install Git and checkout project" | ||
uses: actions/checkout@v4 | ||
|
||
|
@@ -231,11 +232,6 @@ jobs: | |
with: | ||
python-version: ${{ env.MAIN_PYTHON_VERSION }} | ||
|
||
- name: "Install OS packages" | ||
run: | | ||
sudo apt update | ||
sudo apt install pandoc | ||
- name: "Cache pip" | ||
uses: actions/cache@v4 | ||
with: | ||
|
@@ -244,9 +240,9 @@ jobs: | |
restore-keys: | | ||
Python-v${{ env.RESET_PIP_CACHE }}-Linux-${{ env.MAIN_PYTHON_VERSION }} | ||
- name: "Install ansys-math-core" | ||
- name: "Install ansys-math-core and documentation requirements" | ||
run: | | ||
pip install . | ||
pip install .[doc] | ||
- name: "Login in Github container registry" | ||
uses: docker/[email protected] | ||
|
@@ -262,57 +258,54 @@ jobs: | |
MAPDL_IMAGE: '${{ env.DOCKER_PACKAGE }}:${{ env.DOCKER_IMAGE_VERSION_DOCS_BUILD }}' | ||
|
||
- name: "Retrieve AnsysMath version" | ||
id: version | ||
run: | | ||
echo "ANSYSMATH_VERSION=$(python -c 'from ansys.math.core import __version__; print(__version__)')" >> $GITHUB_ENV | ||
echo "ANSYSMATH_VERSION=$(python -c 'from ansys.math.core import __version__; print(__version__)')" >> $GITHUB_OUTPUT | ||
echo "AnsysMath version is: $(python -c "from ansys.math.core import __version__; print(__version__)")" | ||
- name: "Cache examples" | ||
uses: actions/cache@v4 | ||
with: | ||
path: doc/source/examples | ||
key: Examples-v${{ env.RESET_EXAMPLES_CACHE }}-${{ env.ANSYSMATH_VERSION }}-${{ github.sha }} | ||
key: Examples-v${{ env.RESET_EXAMPLES_CACHE }}-${{ steps.version.outputs.ANSYSMATH_VERSION }}-${{ github.sha }} | ||
restore-keys: | | ||
Examples-v${{ env.RESET_EXAMPLES_CACHE }}-${{ env.ANSYSMATH_VERSION }} | ||
Examples-v${{ env.RESET_EXAMPLES_CACHE }}-${{ steps.version.outputs.ANSYSMATH_VERSION }} | ||
- name: "Cache docs build directory" | ||
uses: actions/cache@v4 | ||
with: | ||
path: doc/_build | ||
key: doc-build-v${{ env.RESET_DOC_BUILD_CACHE }}-${{ env.ANSYSMATH_VERSION }}-${{ github.sha }} | ||
key: doc-build-v${{ env.RESET_DOC_BUILD_CACHE }}-${{ steps.version.outputs.ANSYSMATH_VERSION }}-${{ github.sha }} | ||
restore-keys: | | ||
doc-build-v${{ env.RESET_DOC_BUILD_CACHE }}-${{ env.ANSYSMATH_VERSION }} | ||
doc-build-v${{ env.RESET_DOC_BUILD_CACHE }}-${{ steps.version.outputs.ANSYSMATH_VERSION }} | ||
- name: "Cache autosummary" | ||
uses: actions/cache@v4 | ||
with: | ||
path: doc/source/**/_autosummary/*.rst | ||
key: autosummary-v${{ env.RESET_AUTOSUMMARY_CACHE }}-${{ env.ANSYSMATH_VERSION }}-${{ github.sha }} | ||
key: autosummary-v${{ env.RESET_AUTOSUMMARY_CACHE }}-${{ steps.version.outputs.ANSYSMATH_VERSION }}-${{ github.sha }} | ||
restore-keys: | | ||
autosummary-v${{ env.RESET_AUTOSUMMARY_CACHE }}-${{ env.ANSYSMATH_VERSION }} | ||
- name: "Install docs build requirements" | ||
run: | | ||
pip install .[doc] | ||
- name: List | ||
run: pip list | ||
autosummary-v${{ env.RESET_AUTOSUMMARY_CACHE }}-${{ steps.version.outputs.ANSYSMATH_VERSION }} | ||
- name: "Run Ansys documentation building action" | ||
uses: ansys/actions/doc-build@v5 | ||
with: | ||
python-version: ${{ env.MAIN_PYTHON_VERSION }} | ||
checkout: false | ||
skip-install: true | ||
sphinxopts: -j auto | ||
checkout: false | ||
sphinxopts: -j auto --keep-going | ||
requires-xvfb: true | ||
skip-json-build: true | ||
dependencies: pandoc | ||
|
||
|
||
package: | ||
name: Package library | ||
name: "Package library" | ||
needs: [doc-build, build-test] | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Build library source and wheel artifacts | ||
- name: "Build library source and wheel artifacts" | ||
uses: ansys/actions/build-library@v5 | ||
with: | ||
library-name: ${{ env.PACKAGE_NAME }} | ||
|
File renamed without changes.
Empty file.
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