Skip to content

Commit d51cbe9

Browse files
committed
Fix GitHub release pipeline
1 parent 7eab066 commit d51cbe9

4 files changed

Lines changed: 10 additions & 10 deletions

File tree

.github/workflows/publish-release-to-pypi.yaml

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,16 +20,15 @@ jobs:
2020
- name: Set up Python
2121
uses: actions/setup-python@v2
2222
with:
23-
python-version: '3.x'
23+
python-version: "3.x"
2424
- name: Install Python dependencies
2525
run: |
2626
python -m pip install --upgrade pip
27-
pip install -U setuptools wheel twine
27+
pip install -U -r requirements_release.txt
2828
- name: Build and publish release
2929
env:
3030
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
3131
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
3232
run: |
33-
if [ -z ${{ github.event.inputs.version }} ]; then VERSION=${{ github.event.release.tag_name }}; else VERSION=${{ github.event.inputs.version }}; fi
34-
python setup.py sdist bdist_wheel $VERSION
35-
twine upload dist/*
33+
python setup.py sdist bdist_wheel
34+
twine upload dist/*

requirements.txt

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1 @@
1-
requests
2-
setuptools >= 74.1.0
3-
setuptools_git_versioning >= 2.0.0
1+
requests >= 2.32.3

requirements_release.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
setuptools >= 74.1.0
2+
setuptools_git_versioning >= 2.0.0
3+
twine >= 5.1.1
4+
wheel >= 0.44.0

setup.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
import sys
21
import setuptools
32
from pathlib import Path
43

@@ -17,7 +16,7 @@
1716
],
1817
setuptools_git_versioning={
1918
"enabled": True,
20-
"dev_template": "{tag}",
19+
"dev_template": "{tag}",
2120
},
2221
license="GPL-3.0",
2322
description="A Python API for Thermia heat pumps using https://online.thermia.se",

0 commit comments

Comments
 (0)