generated from godotengine/godot-cpp-template
-
Notifications
You must be signed in to change notification settings - Fork 0
106 lines (97 loc) · 3.51 KB
/
builds.yml
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
105
106
name: Build GDExtension
on:
workflow_call:
push:
pull_request:
merge_group:
env:
LIBNAME: godot-s7-scheme
jobs:
build:
strategy:
fail-fast: false
matrix:
include:
# Debug templates
- platform: windows
float-precision: single
arch: x86_64
target-type: template_debug
os: windows-latest
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: true
# Lint
#- name: Setup clang-format
# shell: bash
# run: |
# python -m pip install clang-format
#- name: Run clang-format
# shell: bash
# run: |
# clang-format src/** --dry-run --Werror
# Build
# - name: 🔗 GDExtension Debug Build
# uses: ./.github/actions/build
# with:
# platform: ${{ matrix.platform }}
# arch: ${{ matrix.arch }}
# float-precision: ${{ matrix.float-precision }}
# build-target-type: ${{ matrix.target-type }}
# # Test
# - name: Setup Godot Action
# if: ${{ matrix.float-precision == 'single' && matrix.target-type == 'template_debug' && (matrix.platform == 'linux' || matrix.platform == 'macos' || (matrix.platform == 'windows' && matrix.arch == 'x86_64')) }}
# uses: chickensoft-games/[email protected]
# with:
# version: 4.3.0
# use-dotnet: false
- name: Set GODOT_EXE on windows
if: ${{ matrix.platform == 'windows' }}
run: echo "GODOT_EXE=C:\Users\runneradmin\godot\Godot_v4.3-stable_win64.exe" >> $env:GITHUB_ENV
- name: Env
if: ${{ matrix.platform == 'windows' }}
run: env
- name: Test
if: ${{ matrix.float-precision == 'single' && matrix.target-type == 'template_debug' && (matrix.platform == 'linux' || matrix.platform == 'macos' || (matrix.platform == 'windows' && matrix.arch == 'x86_64')) }}
run: make test -j
# Sign
- name: Mac Sign
# Disable sign if secrets are not set
if: ${{ matrix.platform == 'macos' && env.APPLE_CERT_BASE64 }}
env:
APPLE_CERT_BASE64: ${{ secrets.APPLE_CERT_BASE64 }}
uses: ./.github/actions/sign
with:
FRAMEWORK_PATH: bin/macos/macos.framework
APPLE_CERT_BASE64: ${{ secrets.APPLE_CERT_BASE64 }}
APPLE_CERT_PASSWORD: ${{ secrets.APPLE_CERT_PASSWORD }}
APPLE_DEV_PASSWORD: ${{ secrets.APPLE_DEV_PASSWORD }}
APPLE_DEV_ID: ${{ secrets.APPLE_DEV_ID }}
APPLE_DEV_TEAM_ID: ${{ secrets.APPLE_DEV_TEAM_ID }}
APPLE_DEV_APP_ID: ${{ secrets.APPLE_DEV_APP_ID }}
- name: Windows - Delete compilation files
if: ${{ matrix.platform == 'windows' }}
shell: pwsh
run: |
Remove-Item bin/* -Include *.exp,*.lib,*.pdb -Force
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: godot-s7-scheme-${{ matrix.platform }}-${{ matrix.arch }}-${{ matrix.float-precision }}-${{ matrix.target-type }}
path: |
${{ github.workspace }}/bin/**
# Merges all the build artifacts together into a single godot-s7-scheme artifact.
# If you comment out this step, all the builds will be uploaded individually.
merge:
runs-on: ubuntu-20.04
needs: build
steps:
- name: Merge Artifacts
uses: actions/upload-artifact/merge@v4
with:
name: godot-s7-scheme
pattern: godot-s7-scheme-*
delete-merged: true