Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,3 +28,5 @@
- [ ] I have added tests to cover my changes.
- [ ] All new and existing tests passed.
- [ ] **I have built and run the editor to try this change out.**

<!-- Consider opening a draft PR for initial review. -->
111 changes: 111 additions & 0 deletions .github/workflows/build-avalonia-editor.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,111 @@
name: Build Avalonia Editor

on:
pull_request:
paths:
- '.github/workflows/build-avalonia-editor.yml'
- 'build/Stride.Editor.Avalonia.slnf'
- 'sources/assets/**'
- 'sources/core/**'
- 'sources/editor/**'
- 'sources/presentation/**'
- 'sources/shared/**'
- 'sources/targets/**'
- '!**/.all-contributorsrc'
- '!**/.editorconfig'
- '!**/.gitignore'
- '!**/*.md'
- '!crowdin.yml'
types: [opened, synchronize, reopened, ready_for_review]
workflow_dispatch:
inputs:
build-type:
description: Build Configuration
default: Debug
type: choice
options:
- Debug
- Release
platform:
description: Platform
default: Windows
type: choice
options:
- Windows
- Linux
workflow_call:
inputs:
build-type:
default: Debug
type: string
platform:
default: Windows
type: string

jobs:
Setup:
runs-on: ubuntu-latest
outputs:
build-type: ${{ steps.setup.outputs.build-type }}
platform: ${{ steps.setup.outputs.platform }}
steps:
- id: setup
run: |
echo "build-type=${{ github.event.inputs.build-type || inputs.build-type || 'Debug' }}" >> $GITHUB_OUTPUT
echo "platform=${{ github.event.inputs.platform || inputs.platform || 'Windows' }}" >> $GITHUB_OUTPUT

#
# Build Avalonia Editor on Linux
#
Linux:
needs: Setup
if: ${{ needs.Setup.outputs.platform == 'Linux' }}
name: Linux (${{ needs.Setup.outputs.build-type }})
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
lfs: true
- uses: actions/setup-dotnet@v4
with:
dotnet-version: '8.0.x'
- name: Install dependencies
run: |
sudo apt-get install clang lld
- name: Build
run: |
dotnet build build/Stride.Editor.Avalonia.slnf
-m:1 -nr:false \
-v:m -p:WarningLevel=0 \
-p:Configuration=${{ needs.Setup.outputs.build-type }} \
-p:StridePlatforms=Linux \
-p:StrideGraphicsApis=OpenGL \
-p:StrideSkipUnitTests=true \
-p:StrideSkipAutoPack=true

#
# Build Avalonia Editor on Windows
#
Windows:
needs: Setup
if: ${{ needs.Setup.outputs.platform == 'Windows' }}
name: Windows (${{ needs.Setup.outputs.build-type }})
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
with:
lfs: true
- uses: actions/setup-dotnet@v4
with:
dotnet-version: '8.0.x'
- uses: microsoft/setup-msbuild@v2
- name: Build
run: |
msbuild build\Stride.Editor.Avalonia.slnf `
-restore -m:1 -nr:false `
-v:m -p:WarningLevel=0 `
-p:Configuration=${{ needs.Setup.outputs.build-type }} `
-p:StridePlatforms=Windows `
-p:StrideGraphicsApis=Direct3D11 `
-p:StrideSkipUnitTests=true `
-p:StrideSkipAutoPack=true
20 changes: 11 additions & 9 deletions .github/workflows/build-linux-runtime.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,22 +50,24 @@ jobs:
Linux-Runtime:
if: ${{ github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_call' || github.event.pull_request.draft == false }}
name: Build (${{ github.event.inputs.build-type || inputs.build-type || 'Debug' }}, ${{ github.event.inputs.graphics-api || inputs.graphics-api || 'OpenGL' }})
runs-on: windows-latest
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
lfs: true
- uses: actions/setup-dotnet@v4
with:
dotnet-version: '8.0.x'
- uses: microsoft/setup-msbuild@v2
- name: Install dependencies
run: |
sudo apt-get install clang lld
- name: Build
run: |
msbuild build\Stride.Runtime.sln `
-restore -m:1 -nr:false `
-v:m -p:WarningLevel=0 `
-p:Configuration=${{ github.event.inputs.build-type || inputs.build-type || 'Debug' }} `
-p:StridePlatforms=Linux `
-p:StrideGraphicsApis=${{ github.event.inputs.graphics-api || inputs.graphics-api || 'OpenGL' }} `
-p:StrideSkipUnitTests=true `
dotnet build build/Stride.Runtime.sln \
-m:1 -nr:false \
-v:m -p:WarningLevel=0 \
-p:Configuration=${{ github.event.inputs.build-type || inputs.build-type || 'Debug' }} \
-p:StridePlatforms=Linux \
-p:StrideGraphicsApis=${{ github.event.inputs.graphics-api || inputs.graphics-api || 'OpenGL' }} \
-p:StrideSkipUnitTests=true \
-p:StrideSkipAutoPack=true
1 change: 1 addition & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
push:
branches:
- master
- xplat-editor
paths:
- '.github/workflows/**'
- 'build/**'
Expand Down