forked from algorand/pyteal
-
Notifications
You must be signed in to change notification settings - Fork 0
64 lines (61 loc) · 1.57 KB
/
build.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
53
54
55
56
57
58
59
60
61
62
63
64
name: "Build workflow"
on:
pull_request:
push:
tags:
- v**
branches:
- master
jobs:
build-test:
runs-on: ubuntu-20.04
container: python:${{ matrix.python }}
strategy:
matrix:
python: ['3.10']
steps:
- run: python3 --version
- name: Check out code
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Install python dependencies
run: make setup-development
- name: Build and Test
run: make build-and-test
build-docset:
runs-on: ubuntu-20.04
container: python:3.10 # Needs `make`, can't be slim
steps:
- name: Check out code
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Install python dependencies
run: make setup-docs
- name: Make docs
run: make bundle-docs
- name: Archive docset
uses: actions/upload-artifact@v2
with:
name: pyteal.docset
path: docs/pyteal.docset.tar.gz
upload-to-pypi:
runs-on: ubuntu-20.04
container: python:3.10
needs: ['build-test']
if: ${{ github.event_name == 'push' && startsWith(github.ref, 'refs/tags') }}
steps:
- name: Check out code
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Install dependencies
run: make setup-wheel
- name: Build package
run: make bdist-wheel
- name: Release
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}