This commit is contained in:
Kevin Han 2025-03-17 11:55:17 +00:00 committed by GitHub
commit 7b3130eb34
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1,8 +1,10 @@
name: Release
on:
push:
tags:
- '*'
workflow_dispatch:
inputs:
releaseVersion:
description: 'The target version you want to update and release'
required: true
jobs:
set-package-matrix:
@ -44,11 +46,25 @@ jobs:
pip install setuptools wheel build
- name: Build
run: |
echo $GITHUB_REF_NAME >> ${{ matrix.package-name }}/.version
echo ${{ github.event.inputs.releaseVersion }} >> ${{ matrix.package-name }}/.version
cp LICENSE NOTICE ${{ matrix.package-name }}/
python -m build ${{ matrix.package-name }} --outdir dist/
- name: Publish
uses: pypa/gh-action-pypi-publish@release/v1
with:
skip-existing: true
add-tag:
runs-on: ubuntu-latest
needs: deployment
steps:
- name: Checkout latest code
uses: actions/checkout@v4
- name: Add tag and push to the repository
run: |
git config user.name "API Team"
git config user.email "api-team@thousandeyes.com"
git tag ${{ github.event.inputs.releaseVersion }}
git push origin ${{ github.event.inputs.releaseVersion }}