-
Notifications
You must be signed in to change notification settings - Fork 90
45 lines (38 loc) · 1.17 KB
/
release.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
name: Build distribution
on:
push:
paths-ignore: ['docs/**', '**.rst', '**.md']
pull_request:
paths-ignore: ['docs/**', '**.rst', '**.md']
workflow_dispatch:
schedule:
- cron: '0 6 * * 1'
jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Checkout source
uses: actions/checkout@v3
- name: Set up Python 3.10
uses: actions/setup-python@v4
with:
python-version: "3.10"
- name: Install build dependencies
run: |
pip install --upgrade pip
pip install --upgrade build wheel setuptools
- name: Build distributions
shell: bash -l {0}
run: python -m build
- name: Upload package as artifact to GitHub
if: github.repository == 'quaquel/EMAworkbench'
uses: actions/upload-artifact@v3
with:
name: package
path: dist/
- name: Publish package to PyPI
if: github.repository == 'quaquel/EMAworkbench' && github.event_name =='push' && startsWith(github.ref, 'refs/tags')
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: __token__
password: ${{ secrets.pypi_password }}