Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: use dynamic versioning #24

Merged
merged 13 commits into from
Nov 12, 2024
9 changes: 6 additions & 3 deletions .github/workflows/pypi_publish.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Build and/or Publish
name: PyPI

on:
push:
Expand All @@ -7,6 +7,7 @@ on:

jobs:
build:
name: Build Python Package
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand All @@ -22,8 +23,8 @@ jobs:
id-token: write # IMPORTANT: this permission is mandatory for trusted publishing
contents: write # Needed to upload artifacts to the release
environment:
name: PyPi
url: https://pypi.org/p/airbyte
name: PyPI
url: "${{env.PYPI_PUBLISH_URL}}" # Can be toggled at the repository level between https://pypi.org/p/airbyte and https://test.pypi.org/p/airbyte
if: startsWith(github.ref, 'refs/tags/')
steps:
- uses: actions/download-artifact@v4
Expand All @@ -41,3 +42,5 @@ jobs:

- name: Publish
uses: pypa/[email protected]
with:
repository-url: ${{env.PYPI_PUBLISH_URL}}
10 changes: 7 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
[build-system]
requires = ["poetry-core>=1.0.0"]
build-backend = "poetry.core.masonry.api"
requires = ["poetry-core>=1.0.0", "poetry-dynamic-versioning>=1.0.0,<2.0.0"]
build-backend = "poetry_dynamic_versioning.backend"

[tool.poetry]
name = "airbyte-cdk"
version = "6.5.2"
description = "A framework for writing Airbyte Connectors."
authors = ["Airbyte <[email protected]>"]
license = "MIT"
Expand All @@ -22,6 +21,11 @@ classifiers = [
]
keywords = ["airbyte", "connector-development-kit", "cdk"]

# Python CDK uses dynamic versioning: https://github.com/mtkennerly/poetry-dynamic-versioning
version = "0.0.0" # Version will be replaced by the version of the release tag during publish.

[tool.poetry-dynamic-versioning]
enable = true

[tool.poetry.dependencies]
python = "^3.10"
Expand Down
Loading