File tree Expand file tree Collapse file tree 2 files changed +30
-20
lines changed
Expand file tree Collapse file tree 2 files changed +30
-20
lines changed Original file line number Diff line number Diff line change @@ -3,10 +3,10 @@ name: Publish to PyPI
33on :
44 push :
55 tags :
6- - ' v* ' # Triggers on tags like v1.0.0, v1.2.3, etc.
6+ - " * " # Triggers on tags like v1.0.0, v1.2.3, etc.
77
88permissions :
9- id-token : write # IMPORTANT: mandatory for trusted publishing
9+ id-token : write # IMPORTANT: mandatory for trusted publishing
1010
1111jobs :
1212 build :
@@ -16,20 +16,30 @@ jobs:
1616 name : pypi
1717 url : https://pypi.org/p/laygo
1818 steps :
19- - uses : actions/checkout@v4
20-
21- - name : Set up Python
22- uses : actions/setup-python@v5
23- with :
24- python-version : " 3.12"
25-
26- - name : Install uv
27- uses : astral-sh/setup-uv@v4
28- with :
29- enable-cache : true
30-
31- - name : Build package
32- run : uv build
33-
34- - name : Publish to PyPI
35- uses : pypa/gh-action-pypi-publish@release/v1
19+ - uses : actions/checkout@v4
20+
21+ - name : Set up Python
22+ uses : actions/setup-python@v5
23+ with :
24+ python-version : " 3.12"
25+
26+ - name : Install uv
27+ uses : astral-sh/setup-uv@v4
28+ with :
29+ enable-cache : true
30+
31+ - name : Extract version from tag
32+ id : version
33+ run : echo "VERSION=${GITHUB_REF#refs/tags/v}" >> $GITHUB_OUTPUT
34+
35+ - name : Update version in __init__.py
36+ run : |
37+ sed -i 's/VERSION_NUMBER/${{ steps.version.outputs.VERSION }}/g' laygo/__init__.py
38+ echo "Updated version to ${{ steps.version.outputs.VERSION }}"
39+ cat laygo/__init__.py
40+
41+ - name : Build package
42+ run : uv build
43+
44+ - name : Publish to PyPI
45+ uses : pypa/gh-action-pypi-publish@release/v1
Original file line number Diff line number Diff line change 22Laygo - A lightweight Python library for building resilient, in-memory data pipelines
33"""
44
5- __version__ = "0.1.1 "
5+ __version__ = "VERSION_NUMBER "
66
77from .errors import ErrorHandler
88from .helpers import PipelineContext
You can’t perform that action at this time.
0 commit comments