File tree Expand file tree Collapse file tree 2 files changed +24
-0
lines changed Expand file tree Collapse file tree 2 files changed +24
-0
lines changed Original file line number Diff line number Diff line change
1
+ #! /usr/bin/env -S bash -eu
2
+ if [ ! -e ../../../eng/submodules/sdl/CMakeLists.txt ]; then
3
+ git submodule update --init --recursive --depth 1 ../../../eng/submodules/sdl
4
+ fi
5
+ verout=" $( dirname " $( readlink -f " ${BASH_SOURCE[0]} " ) " ) /version.txt"
6
+ (
7
+ cd ../../../eng/submodules/sdl
8
+ git fetch --tags
9
+ IFS=' ' read -a latest <<< " $(git for-each-ref --sort=-committerdate --count=1 --contains=HEAD " refs/tags/release-3* " )"
10
+ if [[ " ${latest:- } " == " " && " $( git describe --tags --exact-match) " == " preview-" * ]]; then
11
+ IFS=' ' read -a latest <<< " $(git for-each-ref --sort=-committerdate --count=1 --contains=HEAD " refs/tags/preview-3* " )"
12
+ fi
13
+ if [[ " ${latest:- } " != " " ]]; then
14
+ git checkout " ${latest[0]} "
15
+ ver=" $( git describe --tags --exact-match) "
16
+ if [[ " $ver " == " preview-" * ]]; then
17
+ echo " ${ver: 8} -preview" > " $verout "
18
+ else
19
+ echo " ${ver: 8} " > " $verout "
20
+ fi
21
+ fi
22
+ )
23
+ git add ../../../eng/submodules/sdl version.txt
Original file line number Diff line number Diff line change
1
+ 3.1.6-preview
You can’t perform that action at this time.
0 commit comments