-
Notifications
You must be signed in to change notification settings - Fork 49
33 lines (32 loc) · 1.48 KB
/
build.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
name: Cesium for Unreal Samples
on: [push]
jobs:
Package:
runs-on: ["self-hosted","windows","x64","unreal-50"]
steps:
- name: Check out repository code
uses: actions/checkout@v3
with:
submodules: recursive
fetch-depth: 0 # so that `git describe` works.
- name: Set environment variables
run: |
$ENV:SAMPLES_VERSION=$(git describe)
$ENV:SAMPLES_PACKAGE_NAME="CesiumForUnrealSamples-${ENV:SAMPLES_VERSION}"
# Make the package name available to subsequent steps
echo "SAMPLES_PACKAGE_NAME=${ENV:SAMPLES_PACKAGE_NAME}" >> $ENV:GITHUB_ENV
- name: Package Project
run: |
cd "C:/Program Files/Epic Games/UE_5.0/Engine/Build/BatchFiles"
& "C:/Program Files/Epic Games/UE_5.0/Engine/Build/BatchFiles/RunUAT.bat" ZipProjectUp -nocompileeditor -project="${ENV:GITHUB_WORKSPACE}/" -install="${ENV:GITHUB_WORKSPACE}/${ENV:SAMPLES_PACKAGE_NAME}".zip -nocompile
- name: Extract built package
run: |
# Unzip the package ZIP so that it's not a ZIP inside a ZIP when published as a GitHub artifact.
mkdir extracted_package
7z x "${ENV:GITHUB_WORKSPACE}/${ENV:SAMPLES_PACKAGE_NAME}.zip" "-o${ENV:GITHUB_WORKSPACE}/extracted_package"
- name: Publish project package artifact
if: ${{ success() }}
uses: actions/upload-artifact@v3
with:
name: ${{ env.SAMPLES_PACKAGE_NAME}}.zip
path: extracted_package