Skip to content

Commit

Permalink
test: testyml
Browse files Browse the repository at this point in the history
  • Loading branch information
yesinkim committed Jan 20, 2024
1 parent 053cd3a commit 936902c
Showing 1 changed file with 44 additions and 0 deletions.
44 changes: 44 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
on:
push:
tags:
- '*'


name: release
jobs:
pypi-publish:
name: upload release to PyPI
runs-on: ubuntu-latest
# Specifying a GitHub environment is optional, but strongly encouraged
environment: release
permissions:
# IMPORTANT: this permission is mandatory for trusted publishing
id-token: write
steps:
# retrieve your distributions here
- name: Set up Python
uses: actions/setup-python@v3
with:
python-version: '3.x'

- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install setuptools wheel twine
- name: Extract tag name
id: tag
run: echo ::set-output name=TAG_NAME::${GITHUB_REF#refs/tags/}

- name: Update version in setup.py
run: |
VERSION=${{ steps.tag.outputs.TAG_NAME }}
VERSION=${VERSION#v}
sed -i "s/{{VERSION_PLACEHOLDER}}/$VERSION/g" setup.py
- name: Build and publish
run: |
python setup.py sdist bdist_wheel
- name: Publish package distributions to PyPI
uses: pypa/gh-action-pypi-publish@release/v1

0 comments on commit 936902c

Please sign in to comment.