Skip to content

Commit 2f8572b

Browse files
authored
chore: add publish on tag action (#16)
1 parent ddf82ea commit 2f8572b

File tree

2 files changed

+38
-10
lines changed

2 files changed

+38
-10
lines changed

.github/workflows/publish.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Publish
2+
3+
on:
4+
push:
5+
tags:
6+
- '*'
7+
8+
jobs:
9+
build:
10+
runs-on: ubuntu-latest
11+
strategy:
12+
matrix:
13+
python-version: ["3.12"]
14+
steps:
15+
- uses: actions/checkout@v3
16+
- name: Set up Python ${{ matrix.python-version }}
17+
uses: actions/setup-python@v3
18+
with:
19+
python-version: ${{ matrix.python-version }}
20+
- name: Install publish dependencies
21+
run: |
22+
python -m pip install --upgrade pip
23+
pip install '.[publish]'
24+
- name: Build and test wheel
25+
run: |
26+
rm -rf dist/
27+
python -m build --sdist --wheel .
28+
twine check dist/*
29+
- name: Publish
30+
run: |
31+
twine upload --non-interactive --verbose --username __token__ --password "$PYPI_API_TOKEN" dist/*
32+

pyproject.toml

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,19 @@
11
[project]
22
name = "beku-stackabletech"
33
version = "0.0.9"
4-
authors = [
5-
{ name = "Razvan Mihai", email = "razvan.mihai@stackable.tech" }
6-
]
4+
authors = [{ name = "Razvan Mihai", email = "razvan.mihai@stackable.tech" }]
75
description = "Test suite expander for Stackable Kuttl tests."
86
readme = "README.md"
97
requires-python = ">=3.7"
108
classifiers = [
11-
"Programming Language :: Python :: 3",
12-
"License :: OSI Approved :: MIT License",
13-
"Operating System :: OS Independent",
14-
]
15-
dependencies = [
16-
"Jinja2>=3.1.2",
17-
"PyYAML>=6.0"
9+
"Programming Language :: Python :: 3",
10+
"License :: OSI Approved :: MIT License",
11+
"Operating System :: OS Independent",
1812
]
13+
dependencies = ["Jinja2>=3.1.2", "PyYAML>=6.0"]
1914
[project.optional-dependencies]
2015
lint = ['ruff==0.0.275', 'mypy==1.4.0']
16+
publish = ['twine==5.0.0', 'build==1.2.1']
2117

2218
[project.scripts]
2319
beku = "beku.main:main"

0 commit comments

Comments
 (0)