-
Notifications
You must be signed in to change notification settings - Fork 21
48 lines (40 loc) · 1.04 KB
/
test-package.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
name: test distribution build
on:
push:
branches:
- master
tags:
- v*
pull_request:
branches:
- master
workflow_dispatch:
jobs:
build-package:
name: Build and test Python distro
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.x'
- name: Install python-build, check-manifest, and twine
run: |
python -m pip install --upgrade pip setuptools wheel
python -m pip install build check-manifest twine
python -m pip list
- name: Check MANIFEST
run: |
check-manifest --verbose
- name: Build a wheel and a sdist
run: |
python -m build --outdir dist/ .
- name: Verify the distribution
run: twine check dist/*
- name: List contents of sdist
run: python -m tarfile --list dist/cabinetry-*.tar.gz
- name: List contents of wheel
run: python -m zipfile --list dist/cabinetry-*.whl