Skip to content

add path to install rye #12

add path to install rye

add path to install rye #12

Workflow file for this run

# Follow this instruction
# https://packaging.python.org/ja/latest/guides/publishing-package-distribution-releases-using-github-actions-ci-cd-workflows/
name: Publish
on:
push:
# tags: '[0-9]+.[0-9]+.[0-9]+'
jobs:
publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.x'
- name: Install rye
shell: bash
run: |
curl -sSf https://rye-up.com/get | RYE_INSTALL_OPTION="--yes" bash
echo "$HOME/.rye/shims" >> $GITHUB_PATH
- name: Build
run: |
rye build
- name: Publish distribution to Test PyPI
run: |
rye publish --repository testpypi --repository-url https://test.pypi.org/legacy/ \
--token ${{ secrets.TEST_PYPI_API_TOKEN }} --yes
- name: Publish distribution to PyPI
if: startsWith(github.ref, 'refs/tags')
run: |
rye publish --token ${{ secrets.PYPI_API_TOKEN }} --yes