-
Notifications
You must be signed in to change notification settings - Fork 0
104 lines (86 loc) · 3.11 KB
/
release.yml
File metadata and controls
104 lines (86 loc) · 3.11 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
name: Build & Release
# Trigger on version tags: v0.40.10a, v0.41.00, etc.
on:
push:
tags:
- 'v*'
permissions:
contents: write # needed to create releases and upload assets
env:
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true
jobs:
build-windows:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@stable
- name: Verify biged-bridge compiles
working-directory: biged-rs
shell: bash
run: |
export PYO3_PYTHON=$(which python)
cargo check -p biged-bridge
- name: Install dependencies
working-directory: BigEd/launcher
run: pip install -r requirements.txt
- name: Build all executables
working-directory: BigEd/launcher
run: python build.py --production
- name: Copy assets to dist
working-directory: BigEd/launcher
run: |
Copy-Item -Path brick.ico, brick_banner.png -Destination dist/ -ErrorAction SilentlyContinue
shell: pwsh
- name: Create release zip
working-directory: BigEd/launcher/dist
run: |
$files = @('BigEdCC.exe', 'UpdateHelper.exe', 'Setup.exe') + (Get-ChildItem -Name *.ico, *.png -ErrorAction SilentlyContinue)
Compress-Archive -Path $files -DestinationPath BigEdCC-Windows-${{ github.ref_name }}.zip
shell: pwsh
- name: Write version file
working-directory: BigEd/launcher/dist
run: echo "${{ github.ref_name }}" > .bigedcc_version
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: windows-release
path: |
BigEd/launcher/dist/BigEdCC.exe
BigEd/launcher/dist/UpdateHelper.exe
BigEd/launcher/dist/Setup.exe
BigEd/launcher/dist/BigEdCC-Windows-${{ github.ref_name }}.zip
BigEd/launcher/dist/.bigedcc_version
# Linux build (AppImage) — future expansion
# build-linux:
# runs-on: ubuntu-latest
# steps: ...
release:
needs: [build-windows]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Download Windows artifacts
uses: actions/download-artifact@v4
with:
name: windows-release
path: release-assets/
- name: List release assets
run: find release-assets/ -type f | sort
- name: Create GitHub Release
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ github.ref_name }}
name: "BigEd CC ${{ github.ref_name }}"
draft: false
prerelease: ${{ contains(github.ref_name, 'a') || contains(github.ref_name, 'b') }}
generate_release_notes: true
files: |
release-assets/BigEd/launcher/dist/BigEdCC-Windows-${{ github.ref_name }}.zip
release-assets/BigEd/launcher/dist/Setup.exe
release-assets/BigEd/launcher/dist/BigEdCC.exe
release-assets/BigEd/launcher/dist/UpdateHelper.exe