Skip to content

Format and YML CICD fixes #13

Format and YML CICD fixes

Format and YML CICD fixes #13

name: 🏁 Windows Builds
on: push
# on:
# push:
# paths:
# - godot-engine/**
defaults:
run:
working-directory: ./godot-engine
# Global Settings
# SCONS_CACHE for windows must be set in the build environment
env:
# Used for the cache key. Add version suffix to force clean build.
GODOT_BASE_BRANCH: master
SCONSFLAGS: verbose=yes warnings=extra werror=no module_text_server_fb_enabled=yes fontconfig=no
SCONS_CACHE_MSVC_CONFIG: true
concurrency:
# workflow name - PR || fallback to unique run id, this happens when you're not building a PR
# this ensures all branches build properly and cancel their previous runs
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
build-windows:
runs-on: "windows-latest"
name: ${{ matrix.name }}
strategy:
fail-fast: false
matrix:
include:
- name: Editor
cache-name: windows-editor
target: editor
strip: true
tests: false
sconsflags: arch=x86_64 debug_symbols=no windows_subsystem=console optimize=speed production=yes
bin: "./bin/godot.windows.editor.x86_64"
artifact-name: "MirrorGodotEditorWindows"
artifact: true
- name: Template
cache-name: windows-template
target: template_debug
strip: true
tests: false
sconsflags: arch=x86_64 debug_symbols=no optimize=speed
bin: "./bin/godot.windows.template_debug.x86_64"
artifact-name: "windows_release_x86_64"
artifact: true
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
- name: Setup Godot build cache
uses: ./godot-engine/.github/actions/godot-cache
with:
cache-name: ${{ matrix.cache-name }}
continue-on-error: true
- name: Setup python and scons
uses: ./godot-engine/.github/actions/godot-deps
#- name: Download Direct3D 12 SDK components
# run: python ./misc/scripts/install_d3d12_sdk_windows.py
- name: Setup MSVC problem matcher
uses: ammaraskar/msvc-problem-matcher@master
- name: Compilation
uses: ./.github/actions/godot-build
with:
sconsflags: ${{ env.SCONSFLAGS }} ${{ matrix.sconsflags }}
platform: windows
target: ${{ matrix.target }}
tests: ${{ matrix.tests }}
- name: Strip binaries
if: ${{ matrix.strip }}
run: |
Remove-Item bin/* -Include *.exp,*.lib,*.pdb -Force
- name: Move PDB file (if not stripped)
if: ${{ !matrix.strip }}
run: |
dir -Path ./bin/
mv ${{matrix.bin}}.pdb bin/${{ matrix.artifact-name}}.pdb
- name: Prepare artifact
if: ${{ matrix.artifact }}
run: |
mv ${{ matrix.bin }}.exe bin/${{ matrix.artifact-name }}.exe