-
-
Notifications
You must be signed in to change notification settings - Fork 15
36 lines (34 loc) · 1.12 KB
/
pythonpublish.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
name: Upload Python Package
on:
release:
types: [published]
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v3
with:
python-version: '3.x'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -U --user --force-reinstall pep517 setuptools_scm twine
- name: Build and publish
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.PYPI_UPLOAD_TOKEN }}
run: |
python -m pep517.build --binary --source --out-dir wheelhouse .
python -m twine upload --skip-existing wheelhouse/*
- name: Install dependencies
run: |
pip install requests httpie
- name: Build all RTD versions
env:
RTD_AUTH_TOKEN: ${{ secrets.RTD_AUTH_TOKEN }}
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
run: |
python rebuild_all_rtd.py
http POST https://api.netlify.com/api/v1/sites/1ba3a6d4-f1ee-4524-bbec-3edc04720a48/builds "Authorization: Bearer $NETLIFY_AUTH_TOKEN"