Skip to content

chore: Clean up (#6) #22

chore: Clean up (#6)

chore: Clean up (#6) #22

Workflow file for this run

name: Release
on:
push:
permissions:
contents: write # Needed to upload artifacts to the release
id-token: write # Needed for OIDC PyPI publishing
jobs:
build:
name: Build and Inspect Python Package
runs-on: ubuntu-latest
outputs:
package_version: ${{ steps.baipp.outputs.package_version }}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
fetch-depth: 0
- uses: hynek/build-and-inspect-python-package@14c7e53f5d033cfa99f7af916fa59a6f7f356394 # v2.11.0
id: baipp
publish:
name: Publish to PyPI
runs-on: ubuntu-latest
needs: [build]
environment:
name: pypi
url: https://pypi.org/project/target-starrocks/${{ needs.build.outputs.package_version }}
if: startsWith(github.ref, 'refs/tags/')
steps:
- uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
with:
name: Packages
path: dist
- name: Upload wheel to release
uses: svenstaro/upload-release-action@04733e069f2d7f7f0b4aebc4fbdbce8613b03ccd # 2.9.0
with:
repo_token: ${{secrets.GITHUB_TOKEN}}
file: dist/*.whl
tag: ${{github.ref}}
overwrite: true
file_glob: true
- name: Publish
## TODO: create a trusted publisher on PyPI
## https://docs.pypi.org/trusted-publishers/
uses: pypa/gh-action-pypi-publish@67339c736fd9354cd4f8cb0b744f2b82a74b5c70 # v1.12.3