Skip to content

Commit

Permalink
pass pypi url as an input to the shared action instead of using an en…
Browse files Browse the repository at this point in the history
…v var
  • Loading branch information
mikealfare committed Jan 26, 2024
1 parent ae81723 commit 58c203f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
7 changes: 3 additions & 4 deletions .github/actions/publish-pypi/action.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
# requires github environment with PYPI_REPOSITORY_URL defined
name: Publish PyPI

inputs:
deploy-to:
pypi-repository-url:
description: The PyPI index to publish to, test or prod
default: "prod"
required: true
build-command:
description: The command to build distributable artifacts
default: "hatch build"
Expand All @@ -26,4 +25,4 @@ runs:
- name: Publish artifacts
uses: pypa/gh-action-pypi-publish@release/v1
with:
url: ${{ vars.PYPI_REPOSITORY_URL }}
url: ${{ inputs.pypi-repository-url }}
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,4 +58,4 @@ jobs:
- name: Publish to PyPI
uses: ./.github/actions/publish-pypi
with:
deploy-to: ${{ inputs.deploy-to }}
pypi-repository-url: ${{ vars.PYPI_REPOSITORY_URL }}

0 comments on commit 58c203f

Please sign in to comment.