add github actions workflow

This commit is contained in:
2025-09-03 21:22:43 +02:00
parent 70c7042b09
commit e39c386e55
2 changed files with 80 additions and 0 deletions
+79
View File
@@ -0,0 +1,79 @@
name: Build Executables
on:
workflow_dispatch:
inputs:
version:
description: "1.0"
required: true
jobs:
build:
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: "3.x"
- name: Install dependencies
run: pip install -r requirements.txt
- name: Build executable
run: pyinstaller --onefile app.py
- name: Rename executable
run: |
if [[ "$RUNNER_OS" == "Windows" ]]; then
mv dist/app.exe dist/app-windows.exe
elif [[ "$RUNNER_OS" == "Linux" ]]; then
mv dist/app dist/app-linux
elif [[ "$RUNNER_OS" == "macOS" ]]; then
mv dist/app dist/app-macos
fi
shell: bash
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: app-${{ matrix.os }}
path: dist/*
release:
needs: build
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Download all build artifacts
uses: actions/download-artifact@v4
with:
merge-multiple: true
- name: List downloaded files (Debugging)
run: ls -R
- name: Make files executable (Linux/Mac)
run: chmod +x app-* || true
# - name: Create GitHub Release
# uses: softprops/action-gh-release@v2
# with:
# tag_name: ${{ github.event.inputs.version }}
# name: Release ${{ github.event.inputs.version }}
# draft: false
# prerelease: false
# files: |
# app-linux
# app-windows.exe
# app-macos
+1
View File
@@ -3,3 +3,4 @@ PySide6==6.9.2
beautifulsoup4==4.13.5
darkdetect==0.8.0
aria2p==0.12.1
pyinstaller==6.15.0