Skip to content

Commit

Permalink
CI: updated publication workflow
Browse files Browse the repository at this point in the history
jotelha committed Jun 7, 2024
1 parent dc17fdb commit 5c36740
Showing 1 changed file with 11 additions and 10 deletions.
21 changes: 11 additions & 10 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -3,7 +3,7 @@ name: publish
on:
push:
branches:
- master
- main
tags:
- '*'

@@ -18,32 +18,33 @@ jobs:
fetch-depth: 0

- name: Set up Python 3.8
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: 3.8

- name: Install requirements
run: |
pip install --upgrade build
pip install --upgrade setuptools wheel setuptools-scm[toml] importlib-metadata
pip install git+https://github.com/livMatS/dtool-lookup-server.git@master
pip list
pip install git+https://github.com/jic-dtool/dtool-lookup-server.git@master
pip list
- name: Package distribution
run: |
python setup.py sdist bdist_wheel
python -m build
- name: Publish distribution to Test PyPI
uses: pypa/gh-action-pypi-publish@master
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: __token__
password: ${{ secrets.test_pypi_password }}
repository_url: https://test.pypi.org/legacy/
repository-url: https://test.pypi.org/legacy/
verbose: true
skip_existing: true
skip-existing: true

- name: Publish distribution to PyPI
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
uses: pypa/gh-action-pypi-publish@master
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: __token__
password: ${{ secrets.pypi_password }}

0 comments on commit 5c36740

Please sign in to comment.