Merge pull request #25 from iantbeck/master #8
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
name: Continuous Integration | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
branches: | |
- master | |
jobs: | |
build-linux: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Python 3.8 | |
uses: actions/setup-python@v2 | |
with: | |
python-version: 3.8 | |
- name: Add conda to system path | |
run: | | |
# $CONDA is an environment variable pointing to the root of the miniconda directory | |
echo $CONDA/bin >> $GITHUB_PATH | |
- name: Install dependencies | |
shell: bash -l {0} | |
run: | | |
conda install python=3.8 | |
conda install numpy | |
conda install -c conda-forge gpy | |
conda install pytorch | |
conda install pandas | |
conda install -c conda-forge cclib | |
conda install -c conda-forge hyperopt | |
conda install -c conda-forge scikit-learn | |
pip install -e . | |
- name: Test with pytest | |
run: | | |
conda install pytest | |
pytest | |
release_sphinx: | |
#needs: [build] | |
defaults: | |
run: | |
shell: bash -l {0} | |
strategy: | |
fail-fast: false | |
matrix: | |
cfg: | |
- conda-env: docs-cf | |
python-version: 3.8 | |
label: Sphinx | |
runs-on: ubuntu-latest | |
name: "🐍 ${{ matrix.cfg.python-version }} • ${{ matrix.cfg.label }}" | |
runs-on: ${{ matrix.cfg.runs-on }} | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Create Environment | |
uses: conda-incubator/setup-miniconda@v2 | |
with: | |
activate-environment: test | |
environment-file: docs/requirements.yml | |
python-version: ${{ matrix.cfg.python-version }} | |
auto-activate-base: false | |
miniforge-variant: Mambaforge | |
miniforge-version: latest | |
use-mamba: true | |
add-pip-as-python-dependency: true | |
channels: conda-forge | |
- name: Environment Information | |
run: | | |
mamba info | |
mamba list --show-channel-urls | |
- name: Build Documentation | |
run: | | |
python -m pip install . --no-deps | |
cd docs | |
make html | |
- name: GitHub Pages Deploy | |
uses: JamesIves/[email protected] | |
if: github.event_name == 'push' && github.repository == 'CCQC/PES-Learn' && ( startsWith( github.ref, 'refs/tags/' ) || github.ref == 'refs/heads/master' ) | |
with: | |
branch: gh-pages | |
folder: docs/build/html |