- Improved README.md formatting and structure - Added installation instructions for pre-built executables - Included platform-specific examples for Windows, Linux, and macOS - Set up Gitea workflow for automated builds on new releases - Added platform-specific PyInstaller spec files for all supported platforms - Updated repository links to point to repo.anhonesthost.net These changes make the project more accessible to new users and streamline the release process with automatic executable generation for all platforms.
101 lines
2.5 KiB
YAML
101 lines
2.5 KiB
YAML
name: Build and Release
|
|
|
|
on:
|
|
release:
|
|
types: [created]
|
|
|
|
jobs:
|
|
build-windows:
|
|
runs-on: windows-latest
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout@v3
|
|
|
|
- name: Set up Python
|
|
uses: actions/setup-python@v4
|
|
with:
|
|
python-version: '3.11'
|
|
|
|
- name: Install dependencies
|
|
run: |
|
|
python -m pip install --upgrade pip
|
|
pip install pyinstaller
|
|
pip install -r requirements.txt
|
|
|
|
- name: Build executable
|
|
run: |
|
|
pyinstaller macropad.spec
|
|
|
|
- name: Upload Windows artifact
|
|
uses: actions/upload-artifact@v3
|
|
with:
|
|
name: macropad-windows
|
|
path: dist/macropad.exe
|
|
|
|
build-linux:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout@v3
|
|
|
|
- name: Set up Python
|
|
uses: actions/setup-python@v4
|
|
with:
|
|
python-version: '3.11'
|
|
|
|
- name: Install dependencies
|
|
run: |
|
|
python -m pip install --upgrade pip
|
|
pip install pyinstaller
|
|
pip install -r requirements.txt
|
|
|
|
- name: Build executable
|
|
run: |
|
|
pyinstaller macropad_linux.spec
|
|
- name: Upload Linux artifact
|
|
uses: actions/upload-artifact@v3
|
|
with:
|
|
name: macropad-linux
|
|
path: dist/macropad
|
|
|
|
build-macos:
|
|
runs-on: macos-latest
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout@v3
|
|
|
|
- name: Set up Python
|
|
uses: actions/setup-python@v4
|
|
with:
|
|
python-version: '3.11'
|
|
|
|
- name: Install dependencies
|
|
run: |
|
|
python -m pip install --upgrade pip
|
|
pip install pyinstaller
|
|
pip install -r requirements.txt
|
|
|
|
- name: Build executable
|
|
run: |
|
|
pyinstaller macropad_macos.spec
|
|
- name: Upload macOS artifact
|
|
uses: actions/upload-artifact@v3
|
|
with:
|
|
name: macropad-macos
|
|
path: dist/macropad.app
|
|
|
|
attach-to-release:
|
|
needs: [build-windows, build-linux, build-macos]
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Download all artifacts
|
|
uses: actions/download-artifact@v3
|
|
|
|
- name: Attach executables to release
|
|
uses: softprops/action-gh-release@v1
|
|
with:
|
|
files: |
|
|
macropad-windows/macropad.exe
|
|
macropad-linux/macropad
|
|
macropad-macos/macropad.app/**/*
|