Skip to content

v1.4.1

v1.4.1 #32

Workflow file for this run

# This workflow will upload a Python Package to PyPI when a release is created
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python#publishing-to-package-registries
# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
name: Upload Python Package
on:
release:
types: [published]
jobs:
# ---------- PYPI PUBLISH JOB ----------
python-package:
runs-on: ubuntu-latest
permissions:
# IMPORTANT: this permission is mandatory for trusted publishing
id-token: write
# Dedicated environments with protections for publishing are strongly recommended.
# For more information, see: https://docs.github.com/en/actions/deployment/targeting-different-environments/using-environments-for-deployment#deployment-protection-rules
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.11"
- name: Install build tooling
run: |
python -m pip install --upgrade pip
python -m pip install --upgrade build
- name: Build source and wheel
run: python -m build
- name: Upload build artifacts
uses: actions/upload-artifact@v4
with:
name: python-package
path: dist/*
- name: Publish release distributions to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
# ---------- WINDOWS EXE BUILD JOB ----------
build-windows-exe:
runs-on: windows-latest
needs: python-package # Wait for PyPI job
permissions:
# IMPORTANT: this permission is mandatory for trusted publishing
contents: write
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.11"
- name: Install dependencies for building EXE
run: |
python -m pip install --upgrade pip
pip install --only-binary :all: .[gui] pyinstaller
- name: Build Windows EXE with PyInstaller
run: pyinstaller ideeplc/gui.spec --noconfirm
- name: Upload EXE to artifact
uses: actions/upload-artifact@v4
with:
name: iDeepLC-gui
path: dist/*.exe
- name: Upload EXE to GitHub Release
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
tag: ${{ github.ref }}
file: dist/*.exe
file_glob: true