try windows build CI
This commit is contained in:
parent
3dc47f958d
commit
895b56c326
1 changed files with 35 additions and 3 deletions
|
|
@ -1,16 +1,47 @@
|
||||||
name: Build Bevy Game (Linux)
|
name: Build Bevy Game (Linux + Windows)
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
|
||||||
|
build-windows:
|
||||||
runs-on: docker
|
runs-on: docker
|
||||||
container:
|
container:
|
||||||
image: git.rufous-trench.ts.net/crizomb/forgejo-action-rust-bevy:deb13-node20-2
|
image: git.rufous-trench.ts.net/crizomb/forgejo-action-rust-bevy:latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: Install Windows target
|
||||||
|
run: |
|
||||||
|
rustup target add x86_64-pc-windows-gnu
|
||||||
|
|
||||||
|
- name: Build Bevy game (Windows release)
|
||||||
|
run: |
|
||||||
|
export CARGO_BUILD_JOBS=2
|
||||||
|
export RUSTFLAGS="-Ccodegen-units=4 -Cdebuginfo=0"
|
||||||
|
cargo build --release --target x86_64-pc-windows-gnu
|
||||||
|
|
||||||
|
- name: Prepare distribution bundle
|
||||||
|
run: |
|
||||||
|
mkdir -p dist/bevy-santa
|
||||||
|
cp target/x86_64-pc-windows-gnu/release/bevy-santa.exe dist/bevy-santa/
|
||||||
|
cp -r assets dist/bevy-santa/
|
||||||
|
|
||||||
|
- name: Upload game bundle
|
||||||
|
uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: bevy-santa-windows-release
|
||||||
|
path: dist/bevy-santa
|
||||||
|
|
||||||
|
build-linux:
|
||||||
|
runs-on: docker
|
||||||
|
container:
|
||||||
|
image: git.rufous-trench.ts.net/crizomb/forgejo-action-rust-bevy:latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Build Bevy game (release)
|
- name: Build Bevy game (release)
|
||||||
run: |
|
run: |
|
||||||
export CARGO_BUILD_JOBS=2
|
export CARGO_BUILD_JOBS=2
|
||||||
|
|
@ -28,3 +59,4 @@ jobs:
|
||||||
with:
|
with:
|
||||||
name: bevy-santa-linux-release
|
name: bevy-santa-linux-release
|
||||||
path: dist/bevy-santa
|
path: dist/bevy-santa
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue