mirror of
https://github.com/DJ2LS/FreeDATA
synced 2024-05-14 08:04:33 +00:00
48 lines
1.4 KiB
YAML
48 lines
1.4 KiB
YAML
|
name: Build and Release Installer
|
||
|
|
||
|
on:
|
||
|
push:
|
||
|
branches:
|
||
|
- main # or any branch you prefer
|
||
|
|
||
|
jobs:
|
||
|
build-and-release:
|
||
|
runs-on: windows-latest
|
||
|
|
||
|
steps:
|
||
|
- name: Check out repository
|
||
|
uses: actions/checkout@v4
|
||
|
|
||
|
- name: Set up Python 3.11
|
||
|
uses: actions/setup-python@v5
|
||
|
with:
|
||
|
python-version: "3.11"
|
||
|
|
||
|
- name: Install Python dependencies
|
||
|
run: |
|
||
|
python -m pip install --upgrade pip
|
||
|
pip install -r requirements.txt
|
||
|
|
||
|
- name: Build binaries
|
||
|
working-directory: modem
|
||
|
run: |
|
||
|
python3 -m nuitka --remove-output --assume-yes-for-downloads --follow-imports --include-data-dir=lib=lib --include-data-files=lib/codec2/*=lib/codec2/ --include-data-files=config.ini.example=config.ini --standalone server.py --output-filename=freedata-server
|
||
|
|
||
|
- name: Create installer
|
||
|
uses: joncloud/makensis-action@v4
|
||
|
with:
|
||
|
script-file: "freedata-server-nsis-config.nsi"
|
||
|
|
||
|
- name: Upload artifact
|
||
|
uses: actions/upload-artifact@v4
|
||
|
with:
|
||
|
name: 'FreeData-Server-Installer'
|
||
|
path: ../FreeData-Server-Installer.exe
|
||
|
|
||
|
- name: Upload Installer to Release
|
||
|
uses: softprops/action-gh-release@v1
|
||
|
if: startsWith(github.ref, 'refs/tags/v')
|
||
|
with:
|
||
|
draft: true
|
||
|
files: ./FreeData-Server-Installer.exe
|