-
Notifications
You must be signed in to change notification settings - Fork 0
43 lines (37 loc) · 999 Bytes
/
sdist.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
name: Sdist build
on:
push:
paths-ignore:
- ".devcontainer/**"
- ".vscode/**"
- "*.md"
branches:
- "main"
tags:
- "v*"
workflow_dispatch:
jobs:
sdist-build:
name: Source distribution
strategy:
matrix:
os: ["ubuntu-22.04"]
python-verson: ["3.12"]
runs-on: ${{ matrix.os }}
env:
PYTHON: ${{ matrix.python-version }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install Python dependencies
run: python -m pip install build twine
- name: Build sdist
run: python -m build --sdist
- name: Upload sdist data if the Git tag is set
run: python -m twine upload dist/*.tar.gz
if: ${{ contains(github.ref, 'tags/') }}
env:
TWINE_USERNAME: "__token__"
TWINE_PASSWORD: ${{ secrets.PYPI_TOKEN_SCALUQ }}