Files
mxpic_forge/.gitea/workflows/build_relase.yaml
T

47 lines
1.4 KiB
YAML

name: Build Linux and Release mxPIC
on:
release:
[published]
jobs:
build-and-release:
name: Build Linux & Publish Release
# This targets your Docker runner on the Synology NAS
runs-on: ubuntu-latest
steps:
- name: Checkout Code
uses: actions/checkout@v4
- name: Set up Python 3.10
uses: actions/setup-python@v5
with:
python-version: '3.10'
- name: Install Build Dependencies
run: |
python -m pip install --upgrade pip
pip install build wheel mypy Cython setuptools
- name: Run Auto-Builder (Compiles Linux C-extensions & Injects .pyi)
# This generates the linux_x86_64.whl inside the dist/ folder
run: python build_wheel.py
- name: Inject Prebuilt Windows Wheel
# This copies your locally-built Windows wheel into the dist/ folder
# so they sit side-by-side right before the release is published.
run: |
if [ -d "prebuilt_wheels" ]; then
cp prebuilt_wheels/*.whl dist/ || true
echo "✅ Windows wheel staged for release."
else
echo "⚠️ No prebuilt_wheels directory found."
fi
- name: Create Gitea Release
uses: https://gitea.com/actions/release-action@main
with:
# This command scopes up everything currently sitting in the dist/ folder
files: "dist/*.whl"
api_key: ${{ secrets.GITEA_TOKEN }}