From 82c2073570a074c621760bc4e6820f4f44f5ea41 Mon Sep 17 00:00:00 2001 From: amasson Date: Mon, 19 May 2025 15:37:10 +0000 Subject: [PATCH] Add .gitea/actions/build-ue-project-unix.yml --- .gitea/actions/build-ue-project-unix.yml | 58 ++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 .gitea/actions/build-ue-project-unix.yml diff --git a/.gitea/actions/build-ue-project-unix.yml b/.gitea/actions/build-ue-project-unix.yml new file mode 100644 index 0000000..737a1f2 --- /dev/null +++ b/.gitea/actions/build-ue-project-unix.yml @@ -0,0 +1,58 @@ +name: Build Unreal Engine Project +description: Build, cook, and package an Unreal Engine project + +inputs: + platform: + required: true + ue_path: + required: true + project_file: + required: true + configuration: + required: true + output: + required: true + +runs: + using: "composite" + steps: + - name: Extract project name + id: extract + shell: bash + run: | + echo "project_name=$(basename "${{ inputs.project_file }}" .uproject)" >> "$GITHUB_OUTPUT" + + - name: Build Editor (if not Shipping) + if: ${{ inputs.configuration != 'Shipping' }} + shell: bash + run: | + "${{ inputs.ue_path }}/Engine/Build/BatchFiles/Build.sh" \ + "${{ steps.extract.outputs.project_name }}Editor" \ + "${{ inputs.platform }}" \ + "${{ inputs.configuration }}" \ + -project="${{ inputs.project_file }}" \ + -waitmutex \ + -targetplatform=${{ inputs.platform }} + + - name: Build Game + shell: bash + run: | + "${{ inputs.ue_path }}/Engine/Build/BatchFiles/Build.sh" \ + "${{ steps.extract.outputs.project_name }}" \ + "${{ inputs.platform }}" \ + "${{ inputs.configuration }}" \ + -project="${{ inputs.project_file }}" \ + -waitmutex \ + -targetplatform=${{ inputs.platform }} + + - name: Cook and Package + shell: bash + run: | + "${{ inputs.ue_path }}/Engine/Build/BatchFiles/RunUAT.sh" BuildCookRun \ + -project="${{ inputs.project_file }}" \ + -noP4 \ + -platform=${{ inputs.platform }} \ + -clientconfig=${{ inputs.configuration }} \ + -serverconfig=${{ inputs.configuration }} \ + -nocompileeditor -cook -pak -stage -archive \ + -archivedirectory="${{ inputs.output }}"