2022-03-19 16:27:11 +01:00
|
|
|
name: "Publish Packages"
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
tags:
|
|
|
|
- v*
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
publish:
|
|
|
|
name: "Publish Package"
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- name: "Checkout Repository"
|
2024-05-20 20:07:44 +02:00
|
|
|
uses: actions/checkout@v4
|
2022-03-19 16:27:11 +01:00
|
|
|
- name: "Setup Python"
|
2024-05-20 20:07:44 +02:00
|
|
|
uses: actions/setup-python@v5
|
2022-03-19 16:27:11 +01:00
|
|
|
with:
|
2023-10-09 08:21:36 +02:00
|
|
|
python-version: 3.12
|
2022-03-19 16:27:11 +01:00
|
|
|
- name: "Get the tagged version"
|
|
|
|
id: get_version
|
|
|
|
env:
|
|
|
|
GITHUB_REF: ${{ github.ref }}
|
2024-05-18 16:17:59 +02:00
|
|
|
run: echo "VERSION=${GITHUB_REF/refs\/tags\/v/}" >> $GITHUB_OUTPUT
|
2022-03-19 16:27:11 +01:00
|
|
|
shell: bash
|
2023-11-15 08:02:57 +01:00
|
|
|
- name: "Install Dependencies"
|
|
|
|
run: python -m pip install setuptools
|
2022-03-19 16:27:11 +01:00
|
|
|
- name: "Generate Python Package"
|
|
|
|
run: python setup.py sdist
|
|
|
|
- name: "Publish Distribution to PyPI"
|
|
|
|
uses: pypa/gh-action-pypi-publish@master
|
|
|
|
with:
|
|
|
|
password: ${{ secrets.PYPI_PASSWORD }}
|
|
|
|
- name: "Publish Distribution to AUR"
|
|
|
|
run: deploy/arch/deploy.sh $VERSION_TAG
|
|
|
|
env:
|
|
|
|
VERSION_TAG: v${{ steps.get_version.outputs.VERSION }}
|
|
|
|
AUR_KEY: ${{ secrets.AUR_KEY }}
|
|
|
|
AUR_IV: ${{ secrets.AUR_IV }}
|