Skip to content

Commit

Permalink
Adding build_and_deploy workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
itsderek23 committed May 5, 2020
1 parent cc51e33 commit bad549d
Showing 1 changed file with 37 additions and 0 deletions.
37 changes: 37 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,26 @@ jobs:
- run: python setup.py sdist bdist_wheel
- store_artifacts:
path: dist
deploy:
docker:
- image: circleci/python:3.7
steps:
- checkout
- run: python -m venv venv
- run: venv/bin/pip install -r requirements_dev.txt
- run: echo "source /root/project/venv/bin/activate" >> $BASH_ENV
- run: python setup.py sdist bdist_wheel
- run:
name: init .pypirc
command: |
echo -e "[pypi]" >> ~/.pypirc
echo -e "username = $PYPI_USERNAME" >> ~/.pypirc
echo -e "password = $PYPI_PASSWORD" >> ~/.pypirc
- run:
name: upload to pypi
command: twine upload dist/*
- store_artifacts:
path: dist
test:
docker:
- image: themattrix/tox
Expand All @@ -38,3 +58,20 @@ workflows:
build:
jobs:
- build
build_and_deploy:
jobs:
- build:
filters:
tags:
only: /.*/
- test
requires:
- build
- deploy:
requires:
- build
filters:
tags:
only: /[0-9]+(\.[0-9]+)*/
branches:
ignore: /.*/

0 comments on commit bad549d

Please sign in to comment.