-
Notifications
You must be signed in to change notification settings - Fork 2
65 lines (62 loc) · 1.83 KB
/
pullrequest.yaml
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
65
name: Pull Request Builder
on:
pull_request:
branches:
- main
tags:
- "!*"
jobs:
build:
runs-on: ubuntu-latest
strategy:
max-parallel: 4
matrix:
python-version:
- 3.8
- 3.9
- "3.10"
- 3.11
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@65d7f2d534ac1bc67fcd62888c5f4f3d2cb2b236 # v4.7.1
with:
python-version: "${{ matrix.python-version }}"
- name: Run tox
run: |
python -m pip install --upgrade pip
pip install tox poetry
tox -e py
- name: Build
run: poetry build
- uses: codecov/codecov-action@eaaf4bedf32dbdc6b720b63067d99c4d77d6047d # v3.1.4
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: ./coverage.xml
flags: unittests
name: pysolcast
verbose: true
deploy:
needs: [build]
permissions:
id-token: write
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
- name: Fetch history and tags
run: |
git fetch --prune --unshallow
git fetch --depth=1 origin +refs/tags/*:refs/tags/*
- uses: actions/setup-python@65d7f2d534ac1bc67fcd62888c5f4f3d2cb2b236 # v4.7.1
with:
python-version: 3.x
- name: Build
run: |
python -m pip install --upgrade pip
pip install build
python -m build
- name: Publish distribution 📦 to Test PyPI
uses: pypa/gh-action-pypi-publish@b7f401de30cb6434a1e19f805ff006643653240e # v1.8.10
with:
repository-url: https://test.pypi.org/legacy/
skip-existing: true