This commit is contained in:
parent
f8ecc42478
commit
7c43c39eab
35
.gitea/workflows/release.yml
Normal file
35
.gitea/workflows/release.yml
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
name: Release
|
||||||
|
run-name: ${{ gitea.actor }} is runs ci pipeline
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- master
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
packaging:
|
||||||
|
name: Distribution
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
env:
|
||||||
|
EXT_FIX: "5"
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
- name: Set up Python 3.12
|
||||||
|
uses: actions/setup-python@v5
|
||||||
|
with:
|
||||||
|
python-version: '3.12'
|
||||||
|
- name: Install poetry
|
||||||
|
run: python -m pip install poetry chardet
|
||||||
|
- name: Install poetry compiler
|
||||||
|
run: poetry install -E compiler
|
||||||
|
- name: Set poetry version
|
||||||
|
run: PV=$(poetry version -s) && poetry version ${PV}+jar3b${EXT_FIX}
|
||||||
|
- name: Build package
|
||||||
|
run: poetry build
|
||||||
|
- name: Add pypi source
|
||||||
|
run: poetry source add --priority=supplemental ahax https://gitea.example.com/api/packages/pub/pypi
|
||||||
|
- name: Add pypi credentials
|
||||||
|
run: poetry config http-basic.ahax ${{ secrets.REPO_USER }} ${{ secrets.REPO_PASS }}
|
||||||
|
- name: Push to pypi
|
||||||
|
run: poetry publish -r ahax -u ${{ secrets.REPO_USER }} -p ${{ secrets.REPO_PASS }} -n
|
||||||
|
|
@ -1,23 +0,0 @@
|
|||||||
variables:
|
|
||||||
ARTIFACT_PATH: /sln/artifacts
|
|
||||||
|
|
||||||
stages:
|
|
||||||
- package
|
|
||||||
|
|
||||||
publish-pypi:
|
|
||||||
stage: package
|
|
||||||
variables:
|
|
||||||
EXT_FIX: "4"
|
|
||||||
image: python:3.12.4-alpine3.20
|
|
||||||
script:
|
|
||||||
- apk add --no-cache gcc musl-dev
|
|
||||||
- pip install chardet poetry
|
|
||||||
- poetry config virtualenvs.in-project true
|
|
||||||
- poetry install -E compiler
|
|
||||||
- PV=$(poetry version -s) && poetry version ${PV}+jar3b${EXT_FIX}
|
|
||||||
- poetry build
|
|
||||||
- poetry source add --priority=supplemental connectone ${PYPI_REPO_URL}
|
|
||||||
- poetry config http-basic.connectone ${PYPI_REPO_USER} ${PYPI_REPO_PASSWORD}
|
|
||||||
- poetry publish -r connectone -u ${PYPI_REPO_USER} -p ${PYPI_REPO_PASSWORD} -n
|
|
||||||
only:
|
|
||||||
- master
|
|
Loading…
x
Reference in New Issue
Block a user