add pypi publish workflow
This commit is contained in:
34
.github/workflows/publish_pypi.yml
vendored
Normal file
34
.github/workflows/publish_pypi.yml
vendored
Normal file
@@ -0,0 +1,34 @@
|
|||||||
|
on:
|
||||||
|
workflow_call:
|
||||||
|
inputs:
|
||||||
|
artifact-skip:
|
||||||
|
required: false
|
||||||
|
type: boolean
|
||||||
|
default: false
|
||||||
|
artifact-name:
|
||||||
|
required: false
|
||||||
|
type: string
|
||||||
|
default: 'artifact'
|
||||||
|
runs_on:
|
||||||
|
required: false
|
||||||
|
type: string
|
||||||
|
default: 'ubuntu_act_on_20'
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
publish-docker-image:
|
||||||
|
runs-on: ${{ inputs.runs_on }}
|
||||||
|
# container:
|
||||||
|
# image: catthehacker/ubuntu:act-latest
|
||||||
|
env:
|
||||||
|
RUNNER_TOOL_CACHE: /toolcache
|
||||||
|
steps:
|
||||||
|
- uses: actions/download-artifact@v3
|
||||||
|
if: ${{ inputs.artifact-skip != true }}
|
||||||
|
with:
|
||||||
|
name: ${{ inputs.artifact-name }}
|
||||||
|
|
||||||
|
- name: Publish package distributions to PyPI
|
||||||
|
uses: pypa/gh-action-pypi-publish@release/v1
|
||||||
|
with:
|
||||||
|
password: ${{ secrets.PYPI_API_TOKEN }}
|
||||||
|
packages-dir: pub/
|
||||||
Reference in New Issue
Block a user