feat: initial commit
This commit is contained in:
commit
137f84ad0d
1 changed files with 37 additions and 0 deletions
37
action.yml
Normal file
37
action.yml
Normal file
|
@ -0,0 +1,37 @@
|
|||
---
|
||||
|
||||
name: Wheel Package Upload
|
||||
description: Upload a python wheel package to a Forgejo/Gitea package registry
|
||||
inputs:
|
||||
wheel:
|
||||
description: Path to the wheel package(s). Can contain shell glob expressions.
|
||||
default: "dist/*.whl"
|
||||
repository:
|
||||
description: Forgejo/Gitea PyPI repository URL.
|
||||
default: "${GITHUB_SERVER_URL}/api/packages/${GITHUB_REPOSITORY_OWNER}/pypi"
|
||||
username:
|
||||
description: The username with which to authenticate against the repository.
|
||||
default: forgejo-actions
|
||||
password:
|
||||
description: The password with which to authenticate against the repository.
|
||||
default: "${GITHUB_TOKEN}"
|
||||
runs:
|
||||
using: docker
|
||||
image: docker.io/library/python:3.11-bookworm
|
||||
entrypoint: /bin/bash
|
||||
args:
|
||||
- -c
|
||||
- |
|
||||
pip3 install --break-system-packages twine
|
||||
cat > ~/.pypirc <<EOF
|
||||
[distutils]
|
||||
index-servers = forgejo
|
||||
|
||||
[forgejo]
|
||||
repository = ${{ inputs.repository }}
|
||||
username = ${{ inputs.username }}
|
||||
password = ${{ inputs.password }}
|
||||
EOF
|
||||
python3 -m twine upload --repository forgejo ${{ inputs.wheel }}
|
||||
|
||||
|
Loading…
Reference in a new issue