Skip to content

Commit

Permalink
chore: Bumped poetry-core build backend to 1.9.0 and build package …
Browse files Browse the repository at this point in the history
…on every push
  • Loading branch information
edgarrmondragon committed May 15, 2024
1 parent 3dba128 commit 006e166
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
10 changes: 4 additions & 6 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ name: Build and Publish to PyPI
on:
workflow_dispatch:
inputs: {}
release:
types: [published]
push:

permissions:
contents: write # Needed to upload artifacts to the release
Expand Down Expand Up @@ -35,7 +34,7 @@ jobs:
cache: 'poetry'

- name: Check version
if: ${{ github.event.release }}
if: ${{ github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v') }}
run: |
version=$(poetry version | awk '{print $2}')
tag=$(echo "${{ github.ref }}" | awk '{split($0,p,"/"); print p[3]}')
Expand All @@ -51,7 +50,7 @@ jobs:
poetry run scripts/alembic_freeze.py
- name: Release Marker
if: ${{ github.event.release }}
if: ${{ github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v') }}
# The release marker differentiates installations 'in the wild' versus internal dev builds and tests
run: touch src/meltano/core/tracking/.release_marker

Expand All @@ -71,6 +70,7 @@ jobs:
needs: [build]
runs-on: ubuntu-latest
environment: publishing
if: ${{ github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v') }}
steps:
- name: Check out the repository
uses: actions/checkout@v4.1.5
Expand All @@ -86,7 +86,6 @@ jobs:
ls dist/
- name: Upload wheel to release
if: ${{ github.event.release }}
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
Expand All @@ -96,5 +95,4 @@ jobs:
file_glob: true

- name: Publish
if: ${{ github.event.release }}
uses: pypa/gh-action-pypi-publish@v1.8.14
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -569,7 +569,7 @@ module = [
]

[build-system]
requires = ["poetry-core==1.7.0"]
requires = ["poetry-core==1.9.0"]
build-backend = "poetry.core.masonry.api"

[tool.ruff]
Expand Down

0 comments on commit 006e166

Please sign in to comment.