Skip to content

Commit

Permalink
fix: Add environment inputs for publishing (#23)
Browse files Browse the repository at this point in the history
  • Loading branch information
antonagestam committed Dec 17, 2023
1 parent b655670 commit b42d40f
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
10 changes: 10 additions & 0 deletions .github/workflows/python-publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,13 @@ on:
type: "string"
required: false
default: "3.12"
environmnent_name:
type: "string"
required: false
default: "pypi"
environment_url:
type: "string"
required: true

jobs:
build-and-publish:
Expand All @@ -17,6 +24,9 @@ jobs:
permissions:
# permission required for trusted publishing
id-token: write
environment:
name: ${{ inputs.environmnent_name }}
url: ${{ inputs.environment_url }}
steps:
- uses: actions/checkout@v4
- run: git fetch --tags
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ jobs:
uses: less-action/reusables/.github/workflows/python-publish.yaml@v11
with:
requirements_file: "pyproject.toml"
environment_url: https://pypi.org/p/<your-pypi-project-name>
```

### `pre-commit`
Expand Down

0 comments on commit b42d40f

Please sign in to comment.