Skip to content

Commit

Permalink
Convert to GitHub actions (josephhardinee#103)
Browse files Browse the repository at this point in the history
* Added github actions configuration

* Added pull-request to workflow

* Removed travis CI files from repository
  • Loading branch information
josephhardinee authored Jun 23, 2021
1 parent bae6024 commit c25f3cb
Show file tree
Hide file tree
Showing 4 changed files with 70 additions and 98 deletions.
46 changes: 46 additions & 0 deletions .github/workflows/run_pydsd_ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: run_pydsd_ci.yml
on: [push,pull_request ]
jobs:
build_and_publish:
name: Setup Environment, and run test suite
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Setup Environment
uses: conda-incubator/setup-miniconda@v2
with:
python-version: 3.7
mamba-version: "*"
channels: conda-forge,defaults
channel-priority: true
activate-environment: pydsdci
environment-file: pydsd-ci.yml
- name: Run Pytest
shell: bash -l {0}
run: |
pytest
- name: Build package
shell: bash -l {0}
run: |
python -m build --wheel --outdir dist/ .
- name: Publish package to PYPI
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags') && github.ref == 'refs/heads/master'
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: ${{ secrets.PYPI_USERNAME }}
password: ${{secrets.PYPI_PASSWORD}}
#repository_url: https://test.pypi.org/legacy/
- name: Build Documentation
shell: bash -l {0}
run: |
pwd
pip install -e .
cd docs
make clean
make html
- name: Upload Documentation
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags') && github.ref == 'refs/heads/master'
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./docs
47 changes: 0 additions & 47 deletions .travis.yml

This file was deleted.

51 changes: 0 additions & 51 deletions continuous_integration/install.sh

This file was deleted.

24 changes: 24 additions & 0 deletions pydsd-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: pydsdci
channels:
- conda-forge
- defaults
dependencies:
- python=3.7
- pytmatrix=0.3.2 # 0.3.3 has a bug
- coveralls
- pytest
- pytest-cov=2.5
- sphinx_rtd_theme
- numpy
- scipy
- matplotlib
- netcdf4
- sphinx
- numpydoc
- hdf4
- pip
- pip:
- sphinx-gallery
- twine
- wheel
- build

0 comments on commit c25f3cb

Please sign in to comment.