Workflow: Simplify Windows build and fix artifact path
All checks were successful
Build Tamigo CLI / Build Linux Binary (push) Successful in 51s
Build Tamigo CLI / Build Windows Binary (push) Successful in 5s

This commit is contained in:
Daniel Dybing
2026-03-11 14:53:39 +01:00
parent ffcca538bf
commit f30f06ea13

View File

@@ -13,21 +13,16 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
- name: Set up Python - name: Set up Python
uses: actions/setup-python@v5 uses: actions/setup-python@v5
with: with:
python-version: '3.12' python-version: '3.12'
- name: Install dependencies - name: Install dependencies
run: | run: |
python -m pip install --upgrade pip python -m pip install --upgrade pip
pip install -r requirements.txt pip install -r requirements.txt
- name: Build
- name: Build with PyInstaller run: pyinstaller --onefile --name tamigo-cli tamigo.py
run: |
pyinstaller --onefile --name tamigo-cli tamigo.py
- name: Upload Linux Artifact - name: Upload Linux Artifact
uses: actions/upload-artifact@v3 uses: actions/upload-artifact@v3
with: with:
@@ -39,25 +34,21 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
- name: Build Windows executable via Docker
- name: Build Windows executable via Docker (Modern & Robust)
run: | run: |
CONTAINER_NAME="builder-${{ github.run_id }}" # Use a very stable Wine+Python image
docker rm -f $CONTAINER_NAME || true # We don't name the container to avoid conflicts, just use the image directly
docker run --rm \
# Using a more modern Python 3.10 image that handles paths better -v "${{ github.workspace }}:/src" \
docker create --name $CONTAINER_NAME burningtyger/pyinstaller-windows "pip install -r requirements.txt && pyinstaller --onefile --name tamigo-cli tamigo.py" -w /src \
cdrx/pyinstaller-windows \
docker cp . $CONTAINER_NAME:/src sh -c "pip install -r requirements.txt && pyinstaller --onefile --name tamigo-cli tamigo.py"
docker start -a $CONTAINER_NAME
docker cp $CONTAINER_NAME:/src/dist .
docker rm $CONTAINER_NAME
- name: Debug - List output files - name: Debug - List output files
run: ls -R dist/ run: ls -R dist/ || echo "Dist folder not found"
- name: Upload Windows Artifact - name: Upload Windows Artifact
uses: actions/upload-artifact@v3 uses: actions/upload-artifact@v3
with: with:
name: binary-windows name: binary-windows
path: dist/*.exe path: dist/windows/*.exe