Skip to content

Commit e7c6c01

Browse files
authored
fix deployment on release (#11)
* rm publsih on release * bump version * fix indentation
1 parent 0641f2e commit e7c6c01

File tree

2 files changed

+6
-8
lines changed

2 files changed

+6
-8
lines changed

.github/workflows/publish.yml

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
name: Publish to PyPI
22

33
on:
4-
release:
5-
types: [published]
64
workflow_dispatch:
75
inputs:
86
environment:
@@ -17,9 +15,9 @@ on:
1715
jobs:
1816
publish:
1917
runs-on: ubuntu-latest
20-
environment:
21-
name: ${{ github.event_name == 'release' && 'pypi' || github.event.inputs.environment }}
22-
url: ${{ github.event_name == 'release' && 'https://pypi.org/p/wav2aug' || 'https://test.pypi.org/p/wav2aug' }}
18+
environment:
19+
name: ${{ github.event.inputs.environment }}
20+
url: ${{ github.event.inputs.environment == 'pypi' && 'https://pypi.org/p/wav2aug' || 'https://test.pypi.org/p/wav2aug' }}
2321
permissions:
2422
id-token: write
2523
contents: read
@@ -39,14 +37,14 @@ jobs:
3937
run: uv build
4038

4139
- name: Publish to Test PyPI
42-
if: github.event_name == 'workflow_dispatch' && github.event.inputs.environment == 'testpypi'
40+
if: github.event.inputs.environment == 'testpypi'
4341
uses: pypa/gh-action-pypi-publish@release/v1
4442
with:
4543
repository-url: https://test.pypi.org/legacy/
4644
verbose: true
4745

4846
- name: Publish to PyPI
49-
if: github.event_name == 'release' || (github.event_name == 'workflow_dispatch' && github.event.inputs.environment == 'pypi')
47+
if: github.event.inputs.environment == 'pypi'
5048
uses: pypa/gh-action-pypi-publish@release/v1
5149
with:
5250
verbose: true

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
44

55
[project]
66
name = "wav2aug"
7-
version = "0.0.3"
7+
version = "0.0.4"
88
description = "A general purpose speech augmentation policy"
99
readme = "readme.md"
1010
requires-python = ">=3.10"

0 commit comments

Comments
 (0)