Skip to content

Commit b9bc782

Browse files
committed
[ci] add wheel building and deploying jobs
1 parent f8c4946 commit b9bc782

File tree

2 files changed

+49
-0
lines changed

2 files changed

+49
-0
lines changed

.github/workflows/distribution.yml

+43
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
name: distribute
2+
3+
on:
4+
workflow_dispatch:
5+
push:
6+
tags: "v*"
7+
release:
8+
types:
9+
- published
10+
11+
jobs:
12+
13+
dist:
14+
runs-on: ubuntu-latest
15+
steps:
16+
- uses: actions/checkout@v3
17+
with:
18+
fetch-depth: 0
19+
20+
- name: Build SDist and wheel
21+
run: pipx run build
22+
23+
- uses: actions/upload-artifact@v3
24+
with:
25+
path: dist/*
26+
27+
- name: Check metadata
28+
run: pipx run twine check dist/*
29+
30+
publish:
31+
needs: [dist]
32+
runs-on: ubuntu-latest
33+
if: github.event_name == 'release' && github.event.action == 'published'
34+
35+
steps:
36+
- uses: actions/download-artifact@v3
37+
with:
38+
name: artifact
39+
path: dist
40+
41+
- uses: pypa/[email protected]
42+
with:
43+
password: ${{ secrets.pypi_password }}

MANIFEST.in

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
prune **
2+
graft src
3+
graft tests
4+
5+
include LICENSE README.md pyproject.toml setup.py setup.cfg
6+
global-exclude __pycache__ *.py[cod] .*

0 commit comments

Comments
 (0)