Files
LOGAR/.gitea/workflows/release.yml
T
me0nline 96126cdf84
CI Test Suite / Run Component Tests & Pipeline Verification (push) Successful in 1m47s
Release Binaries & Packages / Build & Release Standalone Binaries (Linux & Windows Cross-Compilation) (push) Successful in 1m9s
fix(ci): dynamically install runner python shared lib and nsis for reliable installer generation
2026-09-26 13:38:04 +02:00

56 lines
2.3 KiB
YAML

name: Release Binaries & Packages
on:
push:
tags:
- 'v*'
release:
types: [published]
workflow_dispatch:
inputs:
tag:
description: 'Release tag to publish assets to (default: v0.3.1)'
required: false
default: 'v0.3.1'
jobs:
release:
name: Build & Release Standalone Binaries (Linux & Windows Cross-Compilation)
runs-on: ubuntu-latest
steps:
- name: Checkout Code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install System and Cross-Compilation Build Dependencies
run: |
if command -v apt-get >/dev/null 2>&1; then
echo "[*] Installing Python shared libraries, headers, NSIS, and build dependencies..."
SUDO=""
if [ "$(id -u)" -ne 0 ] && command -v sudo >/dev/null 2>&1; then
SUDO="sudo"
fi
$SUDO apt-get update || true
$SUDO apt-get install -y --no-install-recommends \
build-essential nsis curl tar gzip zip python3-dev libpython3-dev || true
PY_VER=$(python3 -c "import sys; print(f'{sys.version_info.major}.{sys.version_info.minor}')" 2>/dev/null || echo "3.9")
$SUDO apt-get install -y --no-install-recommends "libpython${PY_VER}" "libpython${PY_VER}-dev" "python${PY_VER}-dev" || true
fi
python3 compilation/ensure_pip.py
python3 -m pip install --upgrade pip --break-system-packages 2>/dev/null || python3 -m pip install --upgrade pip 2>/dev/null || true
python3 -m pip install pyinstaller distlib cryptography -r compilation/requirements.txt --break-system-packages 2>/dev/null || python3 -m pip install pyinstaller distlib cryptography -r compilation/requirements.txt
- name: Compile Standalone Binaries (Linux & Windows)
run: |
python3 compilation/package_dist.py --target all
- name: Publish Unified Release Assets
env:
GITEA_TOKEN: ${{ secrets.TAG_TOKEN || github.token }}
GITEA_SERVER_URL: ${{ github.server_url }}
GITEA_REPOSITORY: ${{ github.repository }}
GITEA_REF_NAME: ${{ inputs.tag || github.event.release.tag_name || github.ref_name }}
run: |
python3 compilation/upload_release.py --skip-build