Skip to content

Commit 9882fcd

Browse files
authored
Update main.yml
1 parent 54cbcc2 commit 9882fcd

File tree

1 file changed

+14
-9
lines changed

1 file changed

+14
-9
lines changed

.github/workflows/main.yml

+14-9
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,14 @@ jobs:
1212
- name: Checkout
1313
uses: actions/checkout@v4
1414

15+
- name: Extract Version & Determine Patch
16+
id: version_info
17+
run: |
18+
MAJOR_MINOR=$(grep "const VERSION" Autoload/Constants.gd | awk -F\" '{print $2}')
19+
PATCH=$(git rev-list --count HEAD)
20+
FULL_VERSION="$MAJOR_MINOR.$PATCH"
21+
echo "::set-output name=FULL_VERSION::$FULL_VERSION"
22+
1523
- name: Setup Godot and Export Templates
1624
run: |
1725
wget -q https://downloads.tuxfamily.org/godotengine/3.5.3/Godot_v3.5.3-stable_linux_headless.64.zip
@@ -24,29 +32,26 @@ jobs:
2432
2533
- name: Prepare Directories
2634
run: |
27-
# Cleanup previous exports
28-
rm -rf ./bin/*
29-
30-
# Prepare directories for game exports
31-
mkdir -p ./bin/ExportLinux/UnearthLinux/ ./bin/ExportWindows/Unearth/
35+
rm -rf ./bin
36+
mkdir -p ./bin/ExportLinux/UnearthLinux ./bin/ExportWindows/Unearth
3237
3338
- name: Export Godot Game (Linux)
3439
run: ./Godot_v3.5.3-stable_linux_headless.64 --export "Linux/X11" ./bin/ExportLinux/UnearthLinux/Unearth.x86_64
3540

3641
- name: Export Godot Game (Windows)
3742
run: ./Godot_v3.5.3-stable_linux_headless.64 --export "Windows Desktop" ./bin/ExportWindows/Unearth/Unearth.exe
3843

39-
- name: Replace Icon in Windows Export
40-
run: ./Godot_v3.5.3-stable_linux_headless.64 -s Art/ReplaceIcon.gd Art/UnearthIcon.ico ./bin/ExportWindows/Unearth/Unearth.exe
44+
# - name: Replace Icon in Windows Export
45+
# run: ./Godot_v3.5.3-stable_linux_headless.64 -s Art/ReplaceIcon.gd Art/UnearthIcon.ico ./bin/ExportWindows/Unearth/Unearth.exe
4146

4247
- name: Upload Linux Artifacts
4348
uses: actions/upload-artifact@v3
4449
with:
45-
name: UnearthLinux
50+
name: UnearthLinux-${{ steps.version_info.outputs.FULL_VERSION }}
4651
path: ./bin/ExportLinux/
4752

4853
- name: Upload Windows Artifacts
4954
uses: actions/upload-artifact@v3
5055
with:
51-
name: UnearthWindows
56+
name: UnearthWindows-${{ steps.version_info.outputs.FULL_VERSION }}
5257
path: ./bin/ExportWindows/

0 commit comments

Comments
 (0)