mirror of
https://github.com/LostArtefacts/TRX.git
synced 2025-04-28 20:58:07 +03:00
build: add TR2 installer automatic builds
This commit is contained in:
parent
e2bcd1aeb7
commit
3e2206906e
4 changed files with 28 additions and 1 deletions
4
.github/workflows/job_build_tr2.yml
vendored
4
.github/workflows/job_build_tr2.yml
vendored
|
@ -1,4 +1,4 @@
|
|||
name: Build TR2X
|
||||
name: Build TR2X and the installer
|
||||
|
||||
on:
|
||||
workflow_call:
|
||||
|
@ -19,6 +19,8 @@ jobs:
|
|||
just_target: tr2-package-linux ${{ inputs.target }}
|
||||
- platform: win
|
||||
just_target: tr2-package-win-all ${{ inputs.target }}
|
||||
- platform: win-installer
|
||||
just_target: tr2-package-win-installer ${{ inputs.target }}
|
||||
|
||||
steps:
|
||||
- name: Install dependencies
|
||||
|
|
8
justfile
8
justfile
|
@ -65,6 +65,7 @@ tr1-package-win-installer target='release': (tr1-build-win target) (tr1-build-wi
|
|||
tr2-image-linux force="1": (_docker_build "tools/tr2/docker/game-linux/Dockerfile" "rrdash/tr2x-linux" force)
|
||||
tr2-image-win force="1": (_docker_build "tools/tr2/docker/game-win/Dockerfile" "rrdash/tr2x" force)
|
||||
tr2-image-win-config force="1": (_docker_build "tools/tr2/docker/config/Dockerfile" "rrdash/tr2x-config" force)
|
||||
tr2-image-win-installer force="1": (_docker_build "tools/tr2/docker/installer/Dockerfile" "rrdash/tr2x-installer" force)
|
||||
|
||||
tr2-push-image-linux: (tr2-image-linux "0") (_docker_push "rrdash/tr2x-linux")
|
||||
tr2-push-image-win: (tr2-image-win "0") (_docker_push "rrdash/tr2x")
|
||||
|
@ -72,10 +73,17 @@ tr2-push-image-win: (tr2-image-win "0") (_docker_push "rrdash/
|
|||
tr2-build-linux target='debug': (tr2-image-linux "0") (_docker_run "-e" "TARGET="+target "rrdash/tr2x-linux")
|
||||
tr2-build-win target='debug': (tr2-image-win "0") (_docker_run "-e" "TARGET="+target "rrdash/tr2x")
|
||||
tr2-build-win-config: (tr2-image-win-config "0") (_docker_run "rrdash/tr2x-config")
|
||||
tr2-build-win-installer: (tr2-image-win-installer "0") (_docker_run "rrdash/tr2x-installer")
|
||||
|
||||
tr2-package-linux target='release': (tr2-build-linux target) (_docker_run "rrdash/tr2x-linux" "package")
|
||||
tr2-package-win target='release': (tr2-build-win target) (_docker_run "rrdash/tr2x" "package")
|
||||
tr2-package-win-all target='release': (tr2-build-win target) (tr2-build-win-config) (_docker_run "rrdash/tr2x" "package")
|
||||
tr2-package-win-installer target='release': (tr2-build-win target) (tr2-build-win-config) (_docker_run "rrdash/tr2x" "package" "-o" "tools/installer/TR2X_Installer/Resources/release.zip") (tr2-build-win-installer)
|
||||
#!/bin/sh
|
||||
git checkout "tools/installer/TR2X_Installer/Resources/release.zip"
|
||||
exe_name=TR2X-$(tools/get_version 1)-Installer.exe
|
||||
cp tools/installer/out/TR2X_Installer.exe "${exe_name}"
|
||||
echo "Created ${exe_name}"
|
||||
|
||||
output-release-name tr_version:
|
||||
tools/output_release_name {{tr_version}}
|
||||
|
|
5
tools/tr2/docker/installer/Dockerfile
Normal file
5
tools/tr2/docker/installer/Dockerfile
Normal file
|
@ -0,0 +1,5 @@
|
|||
FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build-env
|
||||
|
||||
ENV HOME /app
|
||||
WORKDIR /app
|
||||
ENTRYPOINT ["/app/tools/tr2/docker/installer/entrypoint.sh"]
|
12
tools/tr2/docker/installer/entrypoint.sh
Executable file
12
tools/tr2/docker/installer/entrypoint.sh
Executable file
|
@ -0,0 +1,12 @@
|
|||
#!/bin/bash
|
||||
set -x
|
||||
set -e
|
||||
|
||||
cd /app/tools/installer/
|
||||
|
||||
export DOTNET_CLI_HOME="/tmp/DOTNET_CLI_HOME"
|
||||
|
||||
shopt -s globstar
|
||||
rm -rf **/bin **/obj **/out/*
|
||||
dotnet restore
|
||||
dotnet publish TR2X_Installer -c Release -o out
|
Loading…
Add table
Add a link
Reference in a new issue