-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ad32124
commit 867fd38
Showing
1 changed file
with
44 additions
and
0 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 |
---|---|---|
@@ -0,0 +1,44 @@ | ||
name: Python package | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
pull_request: | ||
branches: | ||
- '*' | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
python-version: ["2.7"] | ||
dependency: ["django","none"] | ||
|
||
steps: | ||
- uses: actions/checkout@v2.3.4 | ||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Install dependencies | ||
run: | | ||
if [ ${{ matrix.dependency }} == django ]; then pip install Django<2.2; fi | ||
pip install -r requirements-dev.txt | ||
pip install codecov pyOpenSSL | ||
- name: Run tests | ||
run: | | ||
make test check coverage | ||
codecov | ||
- name: Publish a Python distribution to PyPI | ||
uses: pypa/gh-action-pypi-publish@master | ||
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags') | ||
with: | ||
user: ${{ secrets.pypi_user }} | ||
password: ${{ secrets.pypi_password }} |