15 Commits

3 changed files with 75 additions and 18 deletions

View File

@@ -0,0 +1,67 @@
name: Create Executables
on:
workflow_dispatch:
release:
types:
- created
push:
branches:
- github-actions
jobs:
# pyinstaller-build-windows:
# runs-on: windows-latest
# steps:
# - name: Checkout code
# uses: actions/checkout@v4
# - name: Extract Version
# id: get_version
# run: |
# $version = python -c "from version import APP_VERSION; print(APP_VERSION)"
# echo "VERSION=$version" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8
# - name: Create Executable (Windows-x64)
# uses: sayyid5416/pyinstaller@v1
# with:
# python_ver: '3.11'
# python_arch: 'x64'
# spec: 'main.spec'
# requirements: 'requirements.txt'
# upload_exe_with_name: 'Zordon-${{env.VERSION}}-Windows-x64'
# pyinstaller-build-linux:
# runs-on: ubuntu-latest
# steps:
# - name: Checkout code
# uses: actions/checkout@v4
# - name: Extract Version
# id: get_version
# run: |
# version=$(python -c 'from version import APP_VERSION; print(APP_VERSION)')
# echo "VERSION=$version" >> $GITHUB_ENV
# - name: Create Executable (Linux-x64)
# uses: sayyid5416/pyinstaller@v1
# with:
# python_ver: '3.11'
# python_arch: 'x64'
# spec: 'main.spec'
# requirements: 'requirements.txt'
# upload_exe_with_name: 'Zordon-${{env.VERSION}}-Linux-x64'
pyinstaller-build-macos:
runs-on: macos-latest
steps:
# - name: Checkout code
# uses: actions/checkout@v4
# - name: Extract Version
# id: get_version
# run: |
# version=$(python -c 'from version import APP_VERSION; print(APP_VERSION)')
# echo "VERSION=$version" >> $GITHUB_ENV
- name: Create Executable (macOS-arm64)
uses: sayyid5416/pyinstaller@v1
with:
python_ver: '3.11'
python_arch: 'arm64'
spec: 'main.spec'
requirements: 'requirements.txt'
upload_exe_with_name: 'Zordon-testing-macOS-arm64'
options: --onefile

View File

@@ -1,17 +0,0 @@
name: Create Executable (Windows)
on:
workflow_dispatch:
release:
jobs:
pyinstaller-build:
runs-on: windows-latest
steps:
- name: Create Executable (Windows)
uses: sayyid5416/pyinstaller@v1
with:
python_ver: '3.11'
spec: 'main.spec'
requirements: 'requirements.txt'
upload_exe_with_name: 'Zordon'

View File

@@ -49,10 +49,17 @@ if platform.system() == 'Darwin': # macOS
codesign_identity=None,
entitlements_file=None,
)
app = BUNDLE(
coll = COLLECT(
exe,
a.binaries,
a.datas,
strip=False,
upx=True,
upx_exclude=[],
name='server',
)
app = BUNDLE(
coll,
strip=True,
name=f'{APP_NAME}.app',
icon=None,