Skip to content

Commit

Permalink
Fix GitHub release pipeline
Browse files Browse the repository at this point in the history
  • Loading branch information
klejejs committed Sep 3, 2024
1 parent 7eab066 commit d51cbe9
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 10 deletions.
9 changes: 4 additions & 5 deletions .github/workflows/publish-release-to-pypi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,15 @@ jobs:
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.x'
python-version: "3.x"
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
pip install -U setuptools wheel twine
pip install -U -r requirements_release.txt
- name: Build and publish release
env:
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
run: |
if [ -z ${{ github.event.inputs.version }} ]; then VERSION=${{ github.event.release.tag_name }}; else VERSION=${{ github.event.inputs.version }}; fi
python setup.py sdist bdist_wheel $VERSION
twine upload dist/*
python setup.py sdist bdist_wheel
twine upload dist/*
4 changes: 1 addition & 3 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
requests
setuptools >= 74.1.0
setuptools_git_versioning >= 2.0.0
requests >= 2.32.3
4 changes: 4 additions & 0 deletions requirements_release.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
setuptools >= 74.1.0
setuptools_git_versioning >= 2.0.0
twine >= 5.1.1
wheel >= 0.44.0
3 changes: 1 addition & 2 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import sys
import setuptools
from pathlib import Path

Expand All @@ -17,7 +16,7 @@
],
setuptools_git_versioning={
"enabled": True,
"dev_template": "{tag}",
"dev_template": "{tag}",
},
license="GPL-3.0",
description="A Python API for Thermia heat pumps using https://online.thermia.se",
Expand Down

0 comments on commit d51cbe9

Please sign in to comment.