-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy path.gitlab-ci.yml
52 lines (47 loc) · 1.06 KB
/
.gitlab-ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
stages:
- build
- test
- deploy
image: python:latest
build-i686:
image: quay.io/pypa/manylinux1_i686
stage: build
script: /opt/python/cp35-cp35m/bin/python setup.py sdist bdist_wheel
artifacts:
paths:
- dist
build-x86-64:
image: quay.io/pypa/manylinux1_x86_64
stage: build
script: /opt/python/cp35-cp35m/bin/python setup.py sdist bdist_wheel
artifacts:
paths:
- dist
.test: &test
stage: test
script:
- 'python -m pip install dist/syzoj_tools-*-py3-none-manylinux1_x86_64.whl'
- 'syzoj --path=examples/a_plus_b test'
- 'syzoj --path=examples/syzoj2 test'
test-3.7:
<<: *test
image: python:3.7
test-3.6:
<<: *test
image: python:3.6
test-3.5:
<<: *test
image: python:3.5
deploy-pypi:
stage: deploy
environment:
name: pypi
only:
- master
when: manual
script:
- 'python3 -m pip install --upgrade twine'
- 'echo "[server-login]" >> $HOME/.pypirc'
- 'echo "username: $PYPI_USERNAME" >> $HOME/.pypirc'
- 'echo "password: $PYPI_PASSWORD" >> $HOME/.pypirc'
- 'twine upload dist/*'