Skip to content

Commit 3270cf1

Browse files
committed
custom depot
1 parent 326a170 commit 3270cf1

File tree

2 files changed

+50
-35
lines changed

2 files changed

+50
-35
lines changed

action.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,12 @@ inputs:
2525
rootPath:
2626
required: false
2727
description: 'The root path to your builds. This is the base of which depots will search your files.'
28+
customDepot:
29+
required: false
30+
description: 'custom depot path'
31+
customDepotId:
32+
required: false
33+
description: 'custom depot id'
2834
depot1Path:
2935
required: false
3036
description: 'The path to depot1.'
@@ -69,6 +75,8 @@ runs:
6975
firstDepotIdOverride: ${{ inputs.firstDepotIdOverride }}
7076
buildDescription: ${{ inputs.buildDescription }}
7177
rootPath: ${{ inputs.rootPath }}
78+
customDepot: ${{ inputs.customDepot }}
79+
customDepotId: ${{ inputs.customDepotId }}
7280
depot1Path: ${{ inputs.depot1Path }}
7381
depot2Path: ${{ inputs.depot2Path }}
7482
depot3Path: ${{ inputs.depot3Path }}

steam_deploy.sh

Lines changed: 42 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22
set -euo pipefail
33
IFS=$'\n\t'
44

5+
apt-get update
6+
apt-get install -y git
7+
git config --global --add safe.directory '*'
8+
59
steamdir=${STEAM_HOME:-$HOME/Steam}
610
# this is relative to the action
711
contentroot=$(pwd)/$rootPath
@@ -24,46 +28,48 @@ else
2428
fi
2529

2630
i=1;
27-
export DEPOTS="\n "
28-
until [ $i -gt 9 ]; do
29-
eval "currentDepotPath=\$depot${i}Path"
30-
if [ -n "$currentDepotPath" ]; then
31-
# depot1Path uses firstDepotId, depot2Path uses firstDepotId + 1, depot3Path uses firstDepotId + 2...
32-
currentDepot=$((firstDepotId + i - 1))
33-
34-
echo ""
35-
echo "Adding depot${currentDepot}.vdf ..."
36-
echo ""
37-
export DEPOTS="$DEPOTS \"$currentDepot\" \"depot${currentDepot}.vdf\"\n "
38-
cat << EOF > "depot${currentDepot}.vdf"
39-
"DepotBuildConfig"
40-
{
41-
"DepotID" "$currentDepot"
42-
"FileMapping"
43-
{
44-
"LocalPath" "./$currentDepotPath/*"
45-
"DepotPath" "."
46-
"recursive" "1"
47-
}
48-
"FileExclusion" "*.pdb"
49-
"FileExclusion" "**/*_BurstDebugInformation_DoNotShip*"
50-
"FileExclusion" "**/*_BackUpThisFolder_ButDontShipItWithYourGame*"
51-
}
52-
EOF
53-
54-
cat depot${currentDepot}.vdf
55-
echo ""
56-
fi;
57-
58-
i=$((i+1))
59-
done
31+
# export DEPOTS="\n "
32+
# until [ $i -gt 9 ]; do
33+
# eval "currentDepotPath=\$depot${i}Path"
34+
# if [ -n "$currentDepotPath" ]; then
35+
# # depot1Path uses firstDepotId, depot2Path uses firstDepotId + 1, depot3Path uses firstDepotId + 2...
36+
# currentDepot=$((firstDepotId + i - 1))
37+
38+
# echo ""
39+
# echo "Adding depot${currentDepot}.vdf ..."
40+
# echo ""
41+
# export DEPOTS="$DEPOTS \"$currentDepot\" \"depot${currentDepot}.vdf\"\n "
42+
# cat << EOF > "depot${currentDepot}.vdf"
43+
# "DepotBuildConfig"
44+
# {
45+
# "DepotID" "$currentDepot"
46+
# "FileMapping"
47+
# {
48+
# "LocalPath" "./$currentDepotPath/*"
49+
# "DepotPath" "."
50+
# "recursive" "1"
51+
# }
52+
# "FileExclusion" "*.pdb"
53+
# "FileExclusion" "**/*_BurstDebugInformation_DoNotShip*"
54+
# "FileExclusion" "**/*_BackUpThisFolder_ButDontShipItWithYourGame*"
55+
# }
56+
# EOF
57+
58+
# cat depot${currentDepot}.vdf
59+
# echo ""
60+
# fi;
61+
62+
# i=$((i+1))
63+
# done
6064

6165
echo ""
6266
echo "#################################"
6367
echo "# Generating App Manifest #"
6468
echo "#################################"
6569
echo ""
6670

71+
GIT_SHOW=$(git show --quiet)
72+
6773
cat << EOF > "manifest.vdf"
6874
"appbuild"
6975
{
@@ -74,8 +80,9 @@ cat << EOF > "manifest.vdf"
7480
"setlive" "$releaseBranch"
7581
7682
"depots"
77-
{$(echo "$DEPOTS" | sed 's/\\n/\
78-
/g')}
83+
{
84+
"$customDepotId" "$customDepot"
85+
}
7986
}
8087
EOF
8188

0 commit comments

Comments
 (0)