Skip to content

Commit

Permalink
Update release.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
dustalov committed Jul 27, 2024
1 parent d3cbad9 commit 05b0f7e
Showing 1 changed file with 11 additions and 14 deletions.
25 changes: 11 additions & 14 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
name: Release

on:
push:
tags:
- v.*
release:
types: [ published ]

Expand Down Expand Up @@ -35,11 +32,10 @@ jobs:
with:
name: packages
path: dist/
pypi:
if: github.event_name == 'release'
testpypi:
environment:
name: pypi
url: https://pypi.org/p/chinese-whispers
name: testpypi
url: https://test.pypi.org/p/chinese-whispers
permissions:
id-token: write
runs-on: ubuntu-latest
Expand All @@ -52,14 +48,18 @@ jobs:
path: dist/
- name: Publish to TestPyPI
uses: pypa/gh-action-pypi-publish@release/v1
testpypi:
with:
repository-url: https://test.pypi.org/legacy/
skip-existing: true
pypi:
if: github.event_name == 'release'
environment:
name: testpypi
url: https://test.pypi.org/p/chinese-whispers
name: pypi
url: https://pypi.org/p/chinese-whispers
permissions:
id-token: write
runs-on: ubuntu-latest
needs: build
needs: testpypi
steps:
- name: Download packages
uses: actions/download-artifact@v4
Expand All @@ -68,6 +68,3 @@ jobs:
path: dist/
- name: Publish to TestPyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
repository-url: https://test.pypi.org/legacy/
skip-existing: true

0 comments on commit 05b0f7e

Please sign in to comment.