TEST: Publishing Action
All checks were successful
Analysis / SonarCloud (push) Successful in 46s
Analysis / SonarCloud (pull_request) Successful in 41s
Tests / Build and Test (3.11) (pull_request) Successful in 1m19s
Tests / Build and Test (3.12) (pull_request) Successful in 1m24s
Tests / Build and Test (3.13) (pull_request) Successful in 1m24s
All checks were successful
Analysis / SonarCloud (push) Successful in 46s
Analysis / SonarCloud (pull_request) Successful in 41s
Tests / Build and Test (3.11) (pull_request) Successful in 1m19s
Tests / Build and Test (3.12) (pull_request) Successful in 1m24s
Tests / Build and Test (3.13) (pull_request) Successful in 1m24s
This commit is contained in:
parent
1da367ccb1
commit
e9b9fc6ca1
90
.gitea/workflows/publish.yml
Normal file
90
.gitea/workflows/publish.yml
Normal file
@ -0,0 +1,90 @@
|
|||||||
|
name: Upload Python Package
|
||||||
|
|
||||||
|
on:
|
||||||
|
release:
|
||||||
|
types: [ published ]
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
release-build:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
container: catthehacker/ubuntu:act-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- uses: actions/setup-python@v5
|
||||||
|
with:
|
||||||
|
python-version: "3.x"
|
||||||
|
|
||||||
|
- name: Build release distributions
|
||||||
|
run: |
|
||||||
|
python -m pip install build
|
||||||
|
python -m build
|
||||||
|
|
||||||
|
- name: Upload distributions
|
||||||
|
uses: christopherhx/gitea-upload-artifact@v4
|
||||||
|
with:
|
||||||
|
name: release-dists
|
||||||
|
path: dist/
|
||||||
|
|
||||||
|
gitea-publish:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
container: catthehacker/ubuntu:act-latest
|
||||||
|
|
||||||
|
needs:
|
||||||
|
- release-build
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
id-token: write
|
||||||
|
|
||||||
|
environment:
|
||||||
|
name: gitea
|
||||||
|
url: https://git.end-play.xyz/profitroll/-/packages/pypi/libbot
|
||||||
|
|
||||||
|
env:
|
||||||
|
GITHUB_WORKFLOW_REF: ${{ gitea.workflow_ref }}
|
||||||
|
INPUT_REPOSITORY_URL: https://git.end-play.xyz/api/packages/profitroll/pypi
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Retrieve release distributions
|
||||||
|
uses: christopherhx/gitea-download-artifact@v4
|
||||||
|
with:
|
||||||
|
name: release-dists
|
||||||
|
path: dist/
|
||||||
|
|
||||||
|
- name: Publish package distributions to TestPyPI
|
||||||
|
uses: pypa/gh-action-pypi-publish@release/v1
|
||||||
|
with:
|
||||||
|
password: ${{ secrets.PYPI_GITEA_API_TOKEN }}
|
||||||
|
repository-url: https://git.end-play.xyz/api/packages/profitroll/pypi
|
||||||
|
|
||||||
|
pypi-publish:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
container: catthehacker/ubuntu:act-latest
|
||||||
|
|
||||||
|
needs:
|
||||||
|
- release-build
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
id-token: write
|
||||||
|
|
||||||
|
environment:
|
||||||
|
name: pypi
|
||||||
|
|
||||||
|
env:
|
||||||
|
GITHUB_WORKFLOW_REF: ${{ gitea.workflow_ref }}
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Retrieve release distributions
|
||||||
|
uses: christopherhx/gitea-download-artifact@v4
|
||||||
|
with:
|
||||||
|
name: release-dists
|
||||||
|
path: dist/
|
||||||
|
|
||||||
|
- name: Publish package distributions to TestPyPI
|
||||||
|
uses: pypa/gh-action-pypi-publish@release/v1
|
||||||
|
with:
|
||||||
|
password: ${{ secrets.PYPI_PYPI_API_TOKEN }}
|
Loading…
Reference in New Issue
Block a user