2018-12-19 10:19:07 +00:00
|
|
|
---
|
|
|
|
kind: pipeline
|
|
|
|
name: default
|
|
|
|
|
|
|
|
steps:
|
2018-12-19 11:24:24 +00:00
|
|
|
- name: test2.7
|
|
|
|
image: python:2.7-alpine
|
|
|
|
pull: always
|
|
|
|
environment:
|
|
|
|
PY_COLORS: "1"
|
|
|
|
commands:
|
2018-12-19 11:34:49 +00:00
|
|
|
- apk add --no-cache openssl-dev libffi-dev build-base
|
2018-12-19 11:24:24 +00:00
|
|
|
- pip install tox -q
|
|
|
|
- tox -e $(tox -l | grep py27* | xargs | sed 's/ /,/g') -q
|
|
|
|
when:
|
|
|
|
event:
|
|
|
|
- push
|
|
|
|
- tag
|
|
|
|
|
|
|
|
- name: test3.5
|
|
|
|
image: python:3.5-alpine
|
|
|
|
pull: always
|
|
|
|
environment:
|
|
|
|
PY_COLORS: "1"
|
|
|
|
commands:
|
2018-12-19 11:34:49 +00:00
|
|
|
- apk add --no-cache openssl-dev libffi-dev build-base
|
2018-12-19 11:24:24 +00:00
|
|
|
- pip install tox -q
|
|
|
|
- tox -e $(tox -l | grep py35* | xargs | sed 's/ /,/g') -q
|
|
|
|
when:
|
|
|
|
event:
|
|
|
|
- push
|
|
|
|
- tag
|
|
|
|
|
|
|
|
- name: test3.6
|
|
|
|
image: python:3.6-alpine
|
|
|
|
pull: always
|
2018-12-19 10:19:07 +00:00
|
|
|
environment:
|
|
|
|
PY_COLORS: "1"
|
|
|
|
commands:
|
2018-12-19 11:34:49 +00:00
|
|
|
- apk add --no-cache openssl-dev libffi-dev build-base
|
2018-12-19 11:24:24 +00:00
|
|
|
- pip install tox -q
|
|
|
|
- tox -e $(tox -l | grep py36* | xargs | sed 's/ /,/g') -q
|
|
|
|
when:
|
|
|
|
event:
|
|
|
|
- push
|
|
|
|
- tag
|
|
|
|
|
|
|
|
- name: test3.7
|
|
|
|
image: python:3.7-alpine
|
|
|
|
pull: always
|
|
|
|
environment:
|
|
|
|
PY_COLORS: "1"
|
|
|
|
commands:
|
2018-12-19 11:34:49 +00:00
|
|
|
- apk add --no-cache openssl-dev libffi-dev build-base
|
2018-12-19 11:24:24 +00:00
|
|
|
- pip install tox -q
|
|
|
|
- tox -e $(tox -l | grep py37* | xargs | sed 's/ /,/g') -q
|
2018-12-19 10:19:07 +00:00
|
|
|
when:
|
|
|
|
event:
|
|
|
|
- push
|
|
|
|
- tag
|
|
|
|
|
|
|
|
- name: build
|
|
|
|
image: python:3.7-alpine
|
|
|
|
pull: true
|
|
|
|
commands:
|
|
|
|
- python setup.py sdist bdist_wheel
|
|
|
|
when:
|
|
|
|
event:
|
|
|
|
- push
|
|
|
|
- tag
|
2018-12-19 11:24:24 +00:00
|
|
|
depends_on:
|
|
|
|
- test2.7
|
|
|
|
- test3.5
|
|
|
|
- test3.6
|
|
|
|
- test3.7
|
2018-12-19 10:19:07 +00:00
|
|
|
|
|
|
|
- name: checksum
|
|
|
|
image: alpine
|
|
|
|
pull: always
|
|
|
|
commands:
|
|
|
|
- apk add --no-cache coreutils
|
|
|
|
# exclude files
|
|
|
|
# - sha256sum -b files/!(*.out) > CHECKSUMFILE
|
|
|
|
- sha256sum -b dist/* > sha256sum.txt
|
|
|
|
when:
|
|
|
|
event:
|
|
|
|
- push
|
|
|
|
- tag
|
2018-12-19 11:24:24 +00:00
|
|
|
depends_on:
|
|
|
|
- test2.7
|
|
|
|
- test3.5
|
|
|
|
- test3.6
|
|
|
|
- test3.7
|
2018-12-19 10:19:07 +00:00
|
|
|
|
|
|
|
- name: gpg-sign
|
|
|
|
image: plugins/gpgsign:1
|
|
|
|
pull: always
|
|
|
|
settings:
|
|
|
|
key:
|
|
|
|
from_secret: gpgsign_key
|
|
|
|
passphrase:
|
|
|
|
from_secret: gpgsign_passphrase
|
|
|
|
detach_sign: true
|
|
|
|
files:
|
|
|
|
- dist/*
|
|
|
|
when:
|
|
|
|
event:
|
|
|
|
- push
|
|
|
|
- tag
|
2018-12-19 11:24:24 +00:00
|
|
|
depends_on:
|
|
|
|
- test2.7
|
|
|
|
- test3.5
|
|
|
|
- test3.6
|
|
|
|
- test3.7
|
2018-12-19 10:19:07 +00:00
|
|
|
|
|
|
|
- name: publish
|
|
|
|
image: plugins/github-release
|
|
|
|
settings:
|
|
|
|
api_key:
|
|
|
|
from_secret: github_token
|
|
|
|
files:
|
|
|
|
- dist/*
|
|
|
|
- sha256sum.txt
|
|
|
|
when:
|
|
|
|
event:
|
|
|
|
- tag
|
2018-12-19 11:24:24 +00:00
|
|
|
depends_on:
|
|
|
|
- test2.7
|
|
|
|
- test3.5
|
|
|
|
- test3.6
|
|
|
|
- test3.7
|
2018-12-19 10:19:07 +00:00
|
|
|
|
|
|
|
- name: pypi_publish
|
|
|
|
image: xoxys/drone-pypi:0.1.0
|
|
|
|
pull: always
|
|
|
|
settings:
|
|
|
|
username:
|
|
|
|
from_secret: pypi_username
|
|
|
|
password:
|
|
|
|
from_secret: pypi_password
|
|
|
|
repository: https://upload.pypi.org/legacy/
|
|
|
|
skip_build: true
|
|
|
|
when:
|
|
|
|
event:
|
|
|
|
- tag
|
|
|
|
depends_on:
|
2018-12-19 11:24:24 +00:00
|
|
|
- test2.7
|
|
|
|
- test3.5
|
|
|
|
- test3.6
|
|
|
|
- test3.7
|