Skip to content

Commit

Permalink
Merge pull request #3 from warhammerkid/release-automation
Browse files Browse the repository at this point in the history
Add initial publish workflow
  • Loading branch information
warhammerkid authored Jun 12, 2022
2 parents 26be44b + 30e1ea8 commit 6e814a0
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 2 deletions.
38 changes: 38 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Build distribution

on: [push, pull_request]

jobs:
deploy:
runs-on: ubuntu-20.04

steps:
- name: Checkout
uses: actions/checkout@v3

- name: Python setup
uses: actions/setup-python@v4
with:
python-version: '3.x'

- name: Install build dependencies
run: python -m pip install build

- name: Build distributions
run: python -m build

- name: Publish to Test PyPI
if: github.repository == 'warhammerkid/bluetti_mqtt'
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: __token__
password: ${{ secrets.TEST_PYPI_API_TOKEN }}
skip_existing: true
repository_url: https://test.pypi.org/legacy/

- name: Publish tagged to PyPI
if: github.repository == 'warhammerkid/bluetti_mqtt' && github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Change Log

## Unreleased
## 0.6.0

* Added support for configuring username / password / port for MQTT broker
* Added proper signal handling. It now correctly shuts down when sent SIGTERM or SIGINT.
Expand Down
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[metadata]
name = bluetti_mqtt
version = 0.5.1
version = 0.6.0
url = http://github.com/warhammerkid/bluetti_mqtt
author = Stephen Augenstein
author_email = [email protected]
Expand Down

0 comments on commit 6e814a0

Please sign in to comment.