Skip to content

Commit

Permalink
Merge pull request #15 from pytroll/ci-workflows
Browse files Browse the repository at this point in the history
Remove travis and appveyor and add github workflows
  • Loading branch information
djhoese authored Jan 18, 2021
2 parents 1babbde + 8cceded commit 91aec34
Show file tree
Hide file tree
Showing 7 changed files with 93 additions and 88 deletions.
51 changes: 51 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: CI

on: [push, pull_request]

jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: true
matrix:
os: ["windows-latest", "ubuntu-latest", "macos-latest"]
python-version: ["3.9"]

env:
PYTHON_VERSION: ${{ matrix.python-version }}
OS: ${{ matrix.os }}
ACTIONS_ALLOW_UNSECURE_COMMANDS: true

steps:
- name: Checkout source
uses: actions/checkout@v2

- name: Setup Conda Environment
uses: mamba-org/provision-with-micromamba@main
with:
# python-version: ${{ matrix.python-version }}
environment-file: continuous_integration/environment.yaml

- name: Install Donfig
shell: bash -l {0}
run: |
pip install --no-deps -e .
- name: Run unit tests on non-Windows
shell: bash -l {0}
run: |
pytest --cov=donfig donfig --cov-report=xml
if: runner.os != 'Windows'

- name: Run unit tests on Windows
shell: powershell
run: |
pytest --cov=donfig donfig --cov-report=xml
if: runner.os == 'Windows'

- name: Upload unittest coverage to Codecov
uses: codecov/codecov-action@v1
with:
flags: unittests
file: ./coverage.xml
env_vars: OS,PYTHON_VERSION,UNSTABLE
25 changes: 25 additions & 0 deletions .github/workflows/deploy-sdist.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Deploy sdist

on:
release:
types:
- published

jobs:
test:
runs-on: ubuntu-latest

steps:
- name: Checkout source
uses: actions/checkout@v2

- name: Create sdist
shell: bash -l {0}
run: python setup.py sdist

- name: Publish package to PyPI
if: github.event.action == 'published'
uses: pypa/[email protected]
with:
user: __token__
password: ${{ secrets.pypi_password }}
42 changes: 0 additions & 42 deletions .travis.yml

This file was deleted.

12 changes: 6 additions & 6 deletions README.rst
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
Donfig
======

.. image:: https://travis-ci.org/pytroll/donfig.svg?branch=master
:target: https://travis-ci.org/pytroll/donfig
.. image:: https://github.com/pytroll/donfig/workflows/CI/badge.svg?branch=master
:target: https://github.com/pytroll/donfig/actions?query=workflow%3A%22CI%22

.. image:: https://ci.appveyor.com/api/projects/status/mx2xytb89voslo6h/branch/master?svg=true
:target: https://ci.appveyor.com/project/pytroll/donfig/branch/master
.. image:: https://codecov.io/gh/pytroll/donfig/branch/master/graph/badge.svg?token=xmvNtxzdoB
:target: https://codecov.io/gh/pytroll/donfig

.. image:: https://coveralls.io/repos/github/pytroll/donfig/badge.svg?branch=master
:target: https://coveralls.io/github/pytroll/donfig?branch=master
.. image:: https://anaconda.org/conda-forge/donfig/badges/version.svg
:target: https://anaconda.org/conda-forge/donfig/

Donfig is a python library meant to make configuration easier for other
python packages. Donfig can be configured programmatically, by
Expand Down
4 changes: 3 additions & 1 deletion RELEASING.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,6 @@ git tag -a v0.22.45 -m "Version 0.22.45"
See [semver.org](http://semver.org/) on how to write a version number.

6. push changes to github `git push --follow-tags`
7. Verify travis tests passed and deployed sdist and wheel to PyPI
7. Verify github action tests passed
8. Create github release
9. Verify deploy github workflow passes and package deployed to PyPI
39 changes: 0 additions & 39 deletions appveyor.yml

This file was deleted.

8 changes: 8 additions & 0 deletions continuous_integration/environment.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
name: test
channels:
- conda-forge
dependencies:
- pyyaml
- pytest
- pytest-cov
- python=3.9

0 comments on commit 91aec34

Please sign in to comment.