mirror of
https://github.com/283375/arcaea-offline-pyside-ui.git
synced 2025-04-11 05:30:17 +00:00
ci: update build actions
This commit is contained in:
parent
4a09dc210a
commit
cd2e3f51ca
@ -1,6 +1,9 @@
|
||||
name: Build UI from latest `arcaea-offline-*` dependencies
|
||||
run-name: ${{ github.actor }} started a build request.
|
||||
on: [workflow_dispatch]
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
build-windows:
|
||||
runs-on: windows-2022
|
||||
@ -8,16 +11,16 @@ jobs:
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 0
|
||||
- uses: actions/setup-python@v4
|
||||
- uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version: '3.11'
|
||||
python-version: "3.11"
|
||||
|
||||
# install dependencies
|
||||
- run: 'pip install -r requirements.txt'
|
||||
- run: 'pip uninstall arcaea-offline arcaea-offline-ocr -y'
|
||||
- run: 'pip install git+https://github.com/283375/arcaea-offline'
|
||||
- run: 'pip install git+https://github.com/283375/arcaea-offline-ocr'
|
||||
- run: 'pip install nuitka imageio'
|
||||
- run: "pip install -r requirements.txt"
|
||||
- run: "pip uninstall arcaea-offline arcaea-offline-ocr -y"
|
||||
- run: "pip install git+https://github.com/283375/arcaea-offline"
|
||||
- run: "pip install git+https://github.com/283375/arcaea-offline-ocr"
|
||||
- run: "pip install nuitka imageio"
|
||||
- name: Install UPX
|
||||
uses: crazy-max/ghaction-upx@v3
|
||||
with:
|
||||
@ -25,11 +28,11 @@ jobs:
|
||||
|
||||
# release builtin files
|
||||
- run: 'pyside6-lrelease.exe .\ui\resources\lang\en_US.ts .\ui\resources\lang\zh_CN.ts'
|
||||
- run: 'python prebuild.py'
|
||||
- run: "python prebuild.py"
|
||||
- run: 'pyside6-rcc.exe .\ui\resources\resources.qrc -o .\ui\resources\resources_rc.py'
|
||||
|
||||
# build
|
||||
- run: 'python -m nuitka --plugin-enable=upx --enable-plugin=pyside6 --assume-yes-for-downloads --windows-icon-from-ico=./ui/resources/images/icon.png --standalone --onefile index.py'
|
||||
- run: "python -m nuitka --plugin-enable=upx --enable-plugin=pyside6 --assume-yes-for-downloads --windows-icon-from-ico=./ui/resources/images/icon.png --standalone --onefile index.py"
|
||||
|
||||
- uses: actions/upload-artifact@v3
|
||||
with:
|
||||
|
36
.github/workflows/build.yml
vendored
36
.github/workflows/build.yml
vendored
@ -1,6 +1,16 @@
|
||||
name: Build UI
|
||||
run-name: ${{ github.actor }} started a build request.
|
||||
on: [workflow_dispatch]
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
push:
|
||||
tags:
|
||||
- "v[0-9]+.[0-9]+.[0-9]+"
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
discussions: write
|
||||
|
||||
jobs:
|
||||
build-windows:
|
||||
runs-on: windows-2022
|
||||
@ -8,14 +18,14 @@ jobs:
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 0
|
||||
- uses: actions/setup-python@v4
|
||||
- uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version: '3.11'
|
||||
cache: 'pip'
|
||||
python-version: "3.11"
|
||||
cache: "pip"
|
||||
|
||||
# install dependencies
|
||||
- run: 'pip install -r requirements.txt'
|
||||
- run: 'pip install nuitka imageio'
|
||||
- run: "pip install -r requirements.txt"
|
||||
- run: "pip install nuitka imageio"
|
||||
- name: Install UPX
|
||||
uses: crazy-max/ghaction-upx@v3
|
||||
with:
|
||||
@ -23,13 +33,17 @@ jobs:
|
||||
|
||||
# release builtin files
|
||||
- run: 'pyside6-lrelease.exe .\ui\resources\lang\en_US.ts .\ui\resources\lang\zh_CN.ts'
|
||||
- run: 'python prebuild.py'
|
||||
- run: "python prebuild.py"
|
||||
- run: 'pyside6-rcc.exe .\ui\resources\resources.qrc -o .\ui\resources\resources_rc.py'
|
||||
|
||||
# build
|
||||
- run: 'python -m nuitka --plugin-enable=upx --enable-plugin=pyside6 --assume-yes-for-downloads --windows-icon-from-ico=./ui/resources/images/icon.png --standalone --onefile index.py'
|
||||
- run: "python -m nuitka --plugin-enable=upx --enable-plugin=pyside6 --assume-yes-for-downloads --windows-icon-from-ico=./ui/resources/images/icon.png --standalone --onefile index.py"
|
||||
|
||||
- uses: actions/upload-artifact@v3
|
||||
- name: Draft a release
|
||||
uses: softprops/action-gh-release@v2
|
||||
with:
|
||||
name: build-windows
|
||||
path: index.exe
|
||||
discussion_category_name: New releases
|
||||
draft: true
|
||||
generate_release_notes: true
|
||||
files: |
|
||||
index.exe
|
||||
|
Loading…
x
Reference in New Issue
Block a user