-
Notifications
You must be signed in to change notification settings - Fork 3
/
.travis.yml
34 lines (33 loc) · 909 Bytes
/
.travis.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
branches:
only:
- release
- master
language: python
python:
- 3.8
services:
- redis
- postgresql
install: pip install -U tox-travis
before_script:
- export TZ=Asia/Shanghai
- sudo mkdir -p /var/log/zillionare
- sudo chmod 777 /var/log/zillionare
- psql -c 'create database zillionare;' -U postgres
- psql -c "create user zillionare with password '123456';" -U postgres
- psql -c "grant all privileges on database zillionare to zillionare;" -U postgres
- psql --dbname=zillionare --file=omicron/config/sql/v0.6.sql
script: tox
before_deploy:
- pip install poetry
- poetry config repositories.testpypi https://test.pypi.org/legacy/
# todo: switch to official after test pass
- poetry config pypi-token.testpypi $TESTPYPI_TOKEN
- poetry config pypi-token.pypi $PYPI_TOKEN
deploy:
- provider: script
script: poetry publish --build
on:
tags: true
python: 3.8
branch: release