Skip to content

Commit 4e9b1e2

Browse files
committed
add tools to publish on Epic Games Store
Signed-off-by: Gaëtan de Villèle <gdevillele@gmail.com>
1 parent bcc495c commit 4e9b1e2

3 files changed

Lines changed: 99 additions & 0 deletions

File tree

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,6 @@
1+
/epicgamesstore/buildpatchtool
2+
/epicgamesstore/upload
3+
/epicgamesstore/macos
4+
/epicgamesstore/windows
15
libssl/android/output
26
libssl/openssl

epicgamesstore/runTool.sh

Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
#!/bin/bash
2+
3+
# exit when any command fails
4+
set -e
5+
6+
CUBZH_RELEASE_BUILD_VERSION="test2"
7+
8+
SCRIPT_DIR="/Users/gaetan/projects/cubzh/deps/epicgamesstore"
9+
10+
# ------------------------------
11+
# Cubzh release paths
12+
# ------------------------------
13+
14+
_CUBZH_RELEASE_DIR="/Users/gaetan/projects/particubes-private/distribution/builds"
15+
CUBZH_RELEASE_WINDOWS_ABSPATH="${_CUBZH_RELEASE_DIR}/Cubzh.exe"
16+
CUBZH_RELEASE_MACOS_ABSPATH="${_CUBZH_RELEASE_DIR}/Cubzh.zip"
17+
18+
# ------------------------------
19+
# Epic Games Store
20+
# ------------------------------
21+
22+
CLIENTID=""
23+
CLIENTSECRET=""
24+
ORGANIZATION_ID=""
25+
PRODUCT_ID=""
26+
ARTIFACT_ID=""
27+
28+
# ------------------------------
29+
# Prepare upload
30+
# ------------------------------
31+
32+
mkdir -p $SCRIPT_DIR/macos
33+
mkdir -p $SCRIPT_DIR/upload
34+
mkdir -p $SCRIPT_DIR/windows
35+
36+
rm -rf $SCRIPT_DIR/macos/*
37+
rm -rf $SCRIPT_DIR/upload/*
38+
rm -rf $SCRIPT_DIR/windows/*
39+
40+
# ------------------------------
41+
# Upload build
42+
# ------------------------------
43+
44+
# Copy release from project to local directory
45+
# Windows
46+
cp $CUBZH_RELEASE_WINDOWS_ABSPATH $SCRIPT_DIR/windows/Cubzh.exe
47+
# macOS
48+
cp $CUBZH_RELEASE_MACOS_ABSPATH $SCRIPT_DIR/macos/Cubzh.zip
49+
unzip -d $SCRIPT_DIR/macos $SCRIPT_DIR/macos/Cubzh.zip
50+
rm $SCRIPT_DIR/macos/Cubzh.zip
51+
52+
# Send Windows build to Epic Games Store
53+
$SCRIPT_DIR/buildpatchtool/tool/Engine/Binaries/Mac/BuildPatchTool \
54+
-OrganizationId="${ORGANIZATION_ID}" \
55+
-ProductId="${PRODUCT_ID}" \
56+
-ArtifactId="${ARTIFACT_ID}" \
57+
-ClientId="${CLIENTID}" \
58+
-ClientSecret="${CLIENTSECRET}" \
59+
-mode=UploadBinary \
60+
-BuildRoot="${SCRIPT_DIR}/windows" \
61+
-CloudDir="${SCRIPT_DIR}/upload" \
62+
-BuildVersion="${CUBZH_RELEASE_BUILD_VERSION}_windows" \
63+
-AppLaunch="Cubzh.exe" \
64+
-AppArgs=""
65+
66+
# cleanup
67+
rm -rf $SCRIPT_DIR/upload/*
68+
69+
# Send macOS build to Epic Games Store
70+
$SCRIPT_DIR/buildpatchtool/tool/Engine/Binaries/Mac/BuildPatchTool \
71+
-OrganizationId="${ORGANIZATION_ID}" \
72+
-ProductId="${PRODUCT_ID}" \
73+
-ArtifactId="${ARTIFACT_ID}" \
74+
-ClientId="${CLIENTID}" \
75+
-ClientSecret="${CLIENTSECRET}" \
76+
-mode=UploadBinary \
77+
-BuildRoot="${SCRIPT_DIR}/macos" \
78+
-CloudDir="${SCRIPT_DIR}/upload" \
79+
-BuildVersion="${CUBZH_RELEASE_BUILD_VERSION}_macos" \
80+
-AppLaunch="Cubzh.app/Contents/MacOS/Cubzh" \
81+
-AppArgs=""

epicgamesstore/updateTool.sh

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
#!/bin/bash
2+
3+
# exit when any command fails
4+
set -e
5+
6+
# download tool
7+
rm -rf ./buildpatchtool
8+
mkdir ./buildpatchtool
9+
curl -L -o ./buildpatchtool/tool.zip https://launcher-public-service-prod06.ol.epicgames.com/launcher/api/installer/download/BuildPatchTool.zip
10+
11+
# unzip tool
12+
unzip -u -d ./buildpatchtool/tool ./buildpatchtool/tool.zip
13+
14+
rm ./buildpatchtool/tool.zip

0 commit comments

Comments
 (0)