Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use GitHub ci #124

Merged
merged 9 commits into from
Feb 15, 2021
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
39 changes: 39 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: build

on: [ push, pull_request ]

jobs:
build:

runs-on: ubuntu-latest
strategy:
matrix:
python-version: [3.6, 3.7, 3.8, 3.9]
steps:
- uses: actions/checkout@v2
- name: Install packages
run: |
sudo apt-get -y install pandoc
if: matrix.python-version == 3.6
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
# pip install flake8 black pytest
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
if [ -f requirements_dev.txt ]; then pip install -r requirements_dev.txt; fi
- name: Lint with flake8
run: flake8 clisops tests
if: matrix.python-version == 3.6
- name: Check formatting with black
run: black --check --target-version py36 clisops tests
if: matrix.python-version == 3.6
- name: Test with pytest
run: |
pytest -v tests
- name: Build docs 🏗️
run: make docs
if: matrix.python-version == 3.6
27 changes: 14 additions & 13 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,12 @@ jobs:
# apt:
# packages:
# - pandoc
- env: TOXENV=black
name: "Black and flake8 compliance"
python: 3.6
- env: TOXENV=py38
name: "Python3.8 (Linux)"
python: 3.8
# - env: TOXENV=black
# name: "Black and flake8 compliance"
# python: 3.6
# - env: TOXENV=py38
# name: "Python3.8 (Linux)"
# python: 3.8
- if: type=push
env: TOXENV=py38-anaconda
name: "Python3.8 (Linux + Anaconda)"
Expand Down Expand Up @@ -55,7 +55,8 @@ jobs:
- pip install -e .
script:
- py.test --cov clisops
- env:
- if: type=push
env:
- TOXENV=py37-windows
- DESIRED_PYTHON=3.7
- MINICONDA_PATH=$(cygpath --windows /c/miniconda)
Expand Down Expand Up @@ -101,12 +102,12 @@ jobs:
- printenv
install:
- /usr/local/opt/[email protected]/bin/pip3 install -U tox-travis
- env: TOXENV=py37
name: "Python3.7 (Linux)"
python: 3.7
- env: TOXENV=py36
name: "Python3.6 (Linux)"
python: 3.6
# - env: TOXENV=py37
# name: "Python3.7 (Linux)"
# python: 3.7
# - env: TOXENV=py36
# name: "Python3.6 (Linux)"
# python: 3.6
allow_failures:
- env: TOXENV=macOS
- env:
Expand Down
2 changes: 1 addition & 1 deletion CONTRIBUTING.rst
Original file line number Diff line number Diff line change
Expand Up @@ -117,5 +117,5 @@ Before you submit a pull request, check that it meets these guidelines:
your new functionality into a function with a docstring, and add the
feature to the list in README.md.
#. The pull request should work for Python 3.6, 3.7, 3.8, and 3.9. Check
https://travis-ci.com/github/roocs/clisops/pull_requests
https://github.com/roocs/clisops/actions
and make sure that the tests pass for all supported Python versions.
1 change: 1 addition & 0 deletions HISTORY.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ Other Changes
* Using file caching to gather ``mini-esgf-data`` test data.
* Added a ``dev`` recipe for pip installations (`pip install clisops[dev]`).
* Updated pre-commit and pre-commit hooks to newest versions.
* Migrated linux-based integration builds to GitHub CI.


v0.5.1 (2021-01-11)
Expand Down
10 changes: 3 additions & 7 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,9 @@ clisops - climate simulation operations
:target: https://pypi.python.org/pypi/clisops
:alt: Pypi



.. image:: https://img.shields.io/travis/roocs/clisops.svg
:target: https://travis-ci.org/roocs/clisops
:alt: Travis


.. image:: https://github.com/roocs/clisops/workflows/build/badge.svg
:target: https://github.com/roocs/clisops/actions
:alt: Build Status

.. image:: https://readthedocs.org/projects/clisops/badge/?version=latest
:target: https://clisops.readthedocs.io/en/latest/?badge=latest
Expand Down
2 changes: 2 additions & 0 deletions requirements_dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,13 @@ flake8
tox
coverage
Sphinx
sphinx-rtd-theme
twine
pytest
pytest-runner
pre-commit>=2.9.0
black>=20.8b1
nbsphinx
nbconvert
ipython
jinja2>=2.11