Skip to content

CLI for SidePulse

Python

Add PyPI publishing metadata and workflow

Peter Kuhardbbd4e0dd8d4
diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml
new file mode 100644
index 0000000..058ed02
--- /dev/null
+++ b/.github/workflows/publish.yml
@@ -0,0 +1,46 @@
+name: Publish to PyPI
+
+# Publishes to PyPI via OIDC trusted publishing (no API token stored).
+# Triggers when a version tag is pushed, e.g. `git tag v0.1.0 && git push --tags`.
+on:
+ push:
+ tags:
+ - "v*"
+
+jobs:
+ build:
+ name: Build distribution
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v4
+ - uses: actions/setup-python@v5
+ with:
+ python-version: "3.12"
+ - name: Build sdist and wheel
+ run: |
+ python -m pip install --upgrade build
+ python -m build
+ - name: Check metadata
+ run: |
+ python -m pip install --upgrade twine
+ twine check dist/*
+ - uses: actions/upload-artifact@v4
+ with:
+ name: dist
+ path: dist/
+
+ publish:
+ name: Publish to PyPI
+ needs: build
+ runs-on: ubuntu-latest
+ environment:
+ name: pypi
+ url: https://pypi.org/project/sidepulse/
+ permissions:
+ id-token: write # required for trusted publishing
+ steps:
+ - uses: actions/download-artifact@v4
+ with:
+ name: dist
+ path: dist/
+ - uses: pypa/gh-action-pypi-publish@release/v1
diff --git a/LICENSE b/LICENSE
new file mode 100644
index 0000000..673d32a
--- /dev/null
+++ b/LICENSE
@@ -0,0 +1,21 @@
+MIT License
+
+Copyright (c) 2026 Peter Kuhar
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
diff --git a/README.md b/README.md
index 438bd6a..9bc1b6d 100644
--- a/README.md
+++ b/README.md
@@ -6,7 +6,7 @@
They can display the status of an AI agent, battery level, or other system
signals.
-| <img src="media/sidepulse-pro.jpg" alt="SidePulse Pro glowing pink in a MacBook Pro SD card slot" width="400"> | <img src="media/sidepulse-dot.jpg" alt="SidePulse Dot glowing green in a MacBook USB-C port" width="400"> |
+| <img src="https://raw.githubusercontent.com/inteliwear/sidepulse/main/media/sidepulse-pro.jpg" alt="SidePulse Pro glowing pink in a MacBook Pro SD card slot" width="400"> | <img src="https://raw.githubusercontent.com/inteliwear/sidepulse/main/media/sidepulse-dot.jpg" alt="SidePulse Dot glowing green in a MacBook USB-C port" width="400"> |
|:---:|:---:|
| **SidePulse Pro** — eight-LED SD card device for MacBook Pro. | **SidePulse Dot** — tiny two-LED USB-C device. |
diff --git a/pyproject.toml b/pyproject.toml
index 082c1a3..a7e17e7 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -1,5 +1,5 @@
[build-system]
-requires = ["setuptools>=68"]
+requires = ["setuptools>=77"]
build-backend = "setuptools.build_meta"
[project]
@@ -8,10 +8,31 @@ version = "0.1.0"
description = "Command-line and macOS tools for SidePulse Pro and SidePulse Dot."
readme = "README.md"
requires-python = ">=3.10"
+license = "MIT"
+license-files = ["LICENSE"]
+authors = [{ name = "Peter Kuhar", email = "[email protected]" }]
+keywords = ["sidepulse", "led", "macbook", "agent", "status", "cli"]
+classifiers = [
+ "Development Status :: 4 - Beta",
+ "Environment :: Console",
+ "Environment :: MacOS X",
+ "Intended Audience :: Developers",
+ "Operating System :: MacOS :: MacOS X",
+ "Programming Language :: Python :: 3",
+ "Programming Language :: Python :: 3.10",
+ "Programming Language :: Python :: 3.11",
+ "Programming Language :: Python :: 3.12",
+ "Programming Language :: Python :: 3.13",
+ "Topic :: System :: Hardware",
+ "Topic :: System :: Monitoring",
+ "Topic :: Utilities",
+]
dependencies = []
[project.urls]
Homepage = "https://sidepulse.io"
+Repository = "https://github.com/inteliwear/sidepulse"
+Issues = "https://github.com/inteliwear/sidepulse/issues"
[project.optional-dependencies]
status-bar = ["pyobjc-framework-Cocoa>=10", "pyobjc-framework-JavaScriptCore>=10"]
@@ -25,6 +46,7 @@ sidepulse-reply = "sidepulse.reply_classifier:main"
[tool.setuptools.packages.find]
where = ["src"]
+include = ["sidepulse*"]
[tool.setuptools.package-data]
"sidepulse.resources" = ["sd_eject_guard.c", "sdled.wasm"]