Skip to content

Commit

Permalink
Merge 959d259 into bde3730
Browse files Browse the repository at this point in the history
  • Loading branch information
alexm118 committed Aug 24, 2020
2 parents bde3730 + 959d259 commit e989453
Show file tree
Hide file tree
Showing 5 changed files with 78 additions and 21 deletions.
47 changes: 47 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Publish

on:
release:
types: [published]

jobs:
release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1

- name: Set up Python
uses: actions/setup-python@v1
with:
python-version: 3.6

- name: Install Python dependencies
run: python -m pip install --upgrade pip wheel

- name: Build the packages
id: build
run: |
python setup.py sdist bdist_wheel
# Get the name of the .whl and .tar.gz files and set them as
# "outputs" of this step so we can upload them
echo "::set-output name=bdist_wheel::$(cd dist && ls *.whl)"
echo "::set-output name=sdist::$(cd dist && ls *.tar.gz)"
- name: Upload the wheel
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: dist/${{ steps.build.outputs.bdist_wheel }}
asset_name: ${{ steps.build.outputs.bdist_wheel }}
asset_content_type: application/zip

- name: Upload the source distribution
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: dist/${{ steps.build.outputs.sdist }}
asset_name: ${{ steps.build.outputs.sdist }}
asset_content_type: application/gzip
29 changes: 29 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: test

on: [pull_request, push]

jobs:
test:
name: test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1

- name: Set up Python
uses: actions/setup-python@v1
with:
python-version: 3.6

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install tox coveralls
- name: Run tox
run: |
tox
coveralls
env:
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}"

19 changes: 0 additions & 19 deletions .travis.yml

This file was deleted.

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[![Build # Status](https://travis-ci.org/cfpb/owning-a-home-api.svg?branch=master)](https://travis-ci.org/cfpb/owning-a-home-api) [![Coverage Status](https://coveralls.io/repos/cfpb/owning-a-home-api/badge.svg?branch=master)](https://coveralls.io/r/cfpb/owning-a-home-api?branch=master)
![Build Status](https://github.com/cfpb/owning-a-home-api/workflows/test/badge.svg)[![Coverage Status](https://coveralls.io/repos/cfpb/owning-a-home-api/badge.svg?branch=master)](https://coveralls.io/r/cfpb/owning-a-home-api?branch=master)

# Owning a Home API

Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
]

testing_extras = [
"coverage>=4.5.1,<5",
"coverage>=5.0,<6",
"mock==2.0.0",
"model_mommy>=1.6.0,<1.7",
]
Expand Down

0 comments on commit e989453

Please sign in to comment.