Skip to content

Merge pull request #2 from traverseda/nix-flake #38

Merge pull request #2 from traverseda/nix-flake

Merge pull request #2 from traverseda/nix-flake #38

Workflow file for this run

name: Python package
on: [push]
jobs:
build:
strategy:
matrix:
os: [macos-latest, ubuntu-latest, windows-latest]
defaults:
run:
shell: bash
runs-on: ${{ matrix.os }}
# timeout-minutes: 360
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: install python poetry
uses: abatilo/actions-poetry@v2
- name: install project
run: poetry install --all-extras --no-interaction --no-cache -vvv
continue-on-error: true
- run: QT_QPA_PLATFORM=minimal poetry run pyinstaller pysdfscad_qtgui/main.py --onefile --name=pySdfScad-${{runner.os}} --collect-data pysdfscad --collect-data pysdfscad_qtgui --windowed --noupx
- run: brew install create-dmg
if: runner.os == 'macOS'
- run: create-dmg dist/PySdfScad-macOS.dmg dist/pySdfScad-macOS.app
if: runner.os == 'macOS'
- run: rm -R dist/pySdfScad-macOS.app
if: runner.os == 'macOS'
# Optionally verify that it works (provided that it does not need user interaction)
#- run: ./dist/your-code/your-code
- uses: actions/upload-artifact@v3
with:
name: build-${{runner.os}}
path: dist/*
release:
runs-on: ubuntu-latest
needs: [build]
steps:
- uses: actions/download-artifact@v3
with:
path: artifacts/
- name: Display structure of downloaded files
run: ls -R artifacts/
- uses: "marvinpinto/action-automatic-releases@latest"
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
automatic_release_tag: "latest"
prerelease: true
title: "Development Build"
files: artifacts/