Skip to content

Release BlueChi v0.8.0 #8

Release BlueChi v0.8.0

Release BlueChi v0.8.0 #8

Workflow file for this run

name: Publish
on:
push:
tags:
- 'v*.*.*'
jobs:
ghrelease:
name: Create GitHub release for BlueChi
runs-on: ubuntu-latest
container:
image: quay.io/bluechi/build-base:latest
steps:
- name: Checkout sources
uses: actions/checkout@v4
with:
fetch-depth: 0
submodules: 'true'
- name: Mark source directory as safe
run: |
git config --global --add safe.directory $(pwd)
- name: Build source rpm
run: |
./build-scripts/build-srpm.sh
- name: Get BlueChi version
run: |
echo "BLUECHI_VERSION=$(./build-scripts/version.sh)" >> $GITHUB_ENV
- name: Create source zip and tarball
run: |
mkdir -p /tmp/bluechi-${{ env.BLUECHI_VERSION }}
cp -r ./ /tmp/bluechi-${{ env.BLUECHI_VERSION }}/
rm -rf /tmp/bluechi-${{ env.BLUECHI_VERSION }}/.git/
mv /tmp/bluechi-${{ env.BLUECHI_VERSION }}/ ./
zip -r bluechi-${{ env.BLUECHI_VERSION }}.zip bluechi-${{ env.BLUECHI_VERSION }}/
tar czf bluechi-${{ env.BLUECHI_VERSION }}.tar.gz bluechi-${{ env.BLUECHI_VERSION }}/
- name: Release
uses: softprops/action-gh-release@v2
if: startsWith(github.ref, 'refs/tags/')
with:
generate_release_notes: true
prerelease: false
draft: false
token: ${{ secrets.GH_RELEASE_TOKEN }}
files: |
bluechi-${{ env.BLUECHI_VERSION }}.zip
bluechi-${{ env.BLUECHI_VERSION }}.tar.gz
rpmbuild/SRPMS/*.src.rpm
pypipublish:
name: Publish bluechi on PyPi
runs-on: ubuntu-latest
container:
image: quay.io/bluechi/build-base:latest
steps:
- name: Checkout sources
uses: actions/checkout@v4
with:
submodules: 'true'
- name: Install dependencies
run: |
dnf install python3-gobject
python3 -m ensurepip --default-pip
python3 -m pip install --upgrade pip setuptools wheel build
python3 -m pip install -r requirements.txt
python3 -m pip install -r src/bindings/generator/requirements.txt
- name: Generate python bindings
run: |
./build-scripts/generate-bindings.sh python
- name: Build python bindings package
run: |
./build-scripts/build-bindings.sh python
- name: Publish bluechi to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
password: ${{ secrets.PYPI_API_TOKEN }}
packages-dir: src/bindings/python/dist/