Skip to content

Update basic_test.yaml #3

Update basic_test.yaml

Update basic_test.yaml #3

name: PyInstaller Release Builds
on:
push:
branches: [ main, develop ]
workflow_dispatch:
jobs:
pyinstaller_build:
name: Build for ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [windows-latest, ubuntu-latest, macos-latest, ubuntu-24.04-arm]
include:
- os: windows-latest
artifact_name: pyocd-windows
- os: ubuntu-latest
artifact_name: pyocd-linux
- os: macos-latest
artifact_name: pyocd-macos
- os: ubuntu-24.04-arm
artifact_name: pyocd-linux-arm64
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: '3.13'
cache: 'pip'
- name: Install package
run: pip install .
- name: Setup build environment
id: setup
run: python get_site-packages.py
- name: Verify environment
run: |
echo "Site packages: ${{ env.SITE_PACKAGES }}"
python -c "import sys; print(sys.version)"
- name: Build with PyInstaller
run: |
pip install pyinstaller
pyinstaller pyocd.spec --log-level=ERROR --clean
- name: Test binary
run: ./dist/pyocd_sa/pyocd_sa --help
if: success()
- name: Upload artifacts
uses: actions/upload-artifact@v4
if: success()
with:
name: ${{ matrix.artifact_name }}
path: dist/pyocd_sa/*
retention-days: 7