Unverified Commit 236e7dec authored by Tao Feng's avatar Tao Feng Committed by GitHub

feat: add github actions for databuilder (#336)

Signed-off-by: 's avatarTao Feng <fengtao04@gmail.com>
parent bfc6f810
# This workflow will install Python dependencies, run tests and lint with a single version of Python
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
on: pull_request
jobs:
pre-commit:
runs-on: ubuntu-18.04
steps:
- name: Checkout
uses: actions/checkout@v1
- name: Setup python 3.6
uses: actions/setup-python@v1
with:
python-version: 3.6
test-unit:
runs-on: ubuntu-18.04
strategy:
matrix:
python-version: ['3.6.x', '3.7.x']
steps:
- name: Checkout
uses: actions/checkout@v1
- name: Setup python ${{ matrix.python-version }}
uses: actions/setup-python@v1
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: pip3 install -r requirements.txt && pip3 install .[all] && pip3 install codecov
- name: Run python unit tests
run: make test
name: Build and Deploy
on:
push:
branches:
- master
tags:
- '*'
jobs:
build-and-publish-python-module:
name: Build and publish python module to pypi
runs-on: ubuntu-18.04
steps:
- name: Checkout
uses: actions/checkout@v1
- name: Setup python 3.6
uses: actions/setup-python@v1
with:
python-version: 3.6
- name: Add wheel dependency
run: pip install wheel
- name: Generate dist
run: python setup.py sdist bdist_wheel
- name: Publish to PyPI
if: startsWith(github.event.ref, 'refs/tags')
uses: pypa/gh-action-pypi-publish@master
with:
user: __token__
password: ${{ secrets.pypi_password }}
language: python
python:
- '3.6'
- '3.7'
install:
- pip install -r requirements.txt
- pip install .[all]
- pip install codecov
script:
- make test
after_success:
- codecov
deploy:
provider: pypi
user: amundsen-dev
password:
secure: mnOKYrqh1ihznQcSGrn/REY0fcZtnCpXyorhqtyTYX+bjRnxItVWl3NA0jJv7KaC5+bNEoDpBAUz6gPYh52jansfDe55pI+GpLrKL4j8ce32Vd0SIqo4ABP3gFV8Nx6xEqNbnRLnZSzgfUqDqk+epCrbtzfe0srneVavXeGAHNrr3iMX0Z3Im6N3dqTobeROlnU/jF5Dch++w+kqSMo+Wcy8A+JVUeXYl5r6UTuUqNUgThvv5mowEcENDea3WAQ7qroR1siASGNCNWWNkmJ/oW+UJnlInQiHDpnQQY7GAiM0tZ+KNIjq2bG8LYMOcvrm4/OsVtZdhuGfxw+4sp7ajgPclDVUHJI67QHfzhpQ6KtIRrcyTI1Rwr9SX7d5nW4e++2d3q2yZyw2NoPjcIOGAcw9TRNvpG/oIig4TeaDzkrZmt9kD4wzI9n2HZ5p0nnn2mF4Xq7ZnaqohJfWx0pCQCQ2GO5+nApyRLAcYr4FdzGnpz+xTjAGEOvtRcYnLzmnq6a1AFkZSRkGdETDF3Pxn+kSha+L28I8MV3pxV6eX9WZ9LXhiIBobrOStE8jGLKqyYLw8MYU1XVNhP2M3lStJ3fGp0zCHFq4a+vewSgvVRfFdtudnu/ZrgJOfekr7dT5NS0R5MxVXSWrKK5JV2vTsXzzBd4+UcGm7IabqAk2rCU=
distributions: sdist bdist_wheel
skip_existing: true
on:
tags: true
repo: amundsen-io/amundsendatabuilder
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment