Skip to content

Commit

Permalink
code cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
CodeSchwert committed Jul 9, 2024
1 parent c01d71f commit 3aa281e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 17 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-game-bridge.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ on:

env:
# TS_SDK_TAG: ${{ github.event.inputs.ts_sdk_tag }}
TS_SDK_TAG: "1.44.0"
TS_SDK_TAG: "1.44.1"
# GAME_ENGINE: ${{ github.event.inputs.game_engine }}
GAME_ENGINE: "Unity"
# DRY_RUN: ${{ github.event.inputs.dry_run }}
Expand Down
20 changes: 4 additions & 16 deletions packages/game-bridge/scripts/updateSdkVersion.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,6 @@ do
fi
done

# pull down latest tags
# git fetch --tags

# get latest git tag
# TS_SDK_TAG=$(git tag -l --sort=-v:refname | grep -v '\-alpha' | head -n 1)

# get the current tag
# CURRENT_TAG=$(git describe --tags --abbrev=0)

# check the TS_SDK_TAG environment variable is set
if [ -z "$TS_SDK_TAG" ]; then
echo "TS_SDK_TAG environment variable not found. Exiting..."
Expand All @@ -42,17 +33,14 @@ if [ -z "$TS_SDK_HASH" ]; then
fi

# use regex to check the current tag is a valid version
if [[ ! $TS_SDK_TAG =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
# example valid version: 1.2.3
# or: 1.2.3-alpha
# or: 1.2.3-alpha.1
if [[ ! $TS_SDK_TAG =~ ^[0-9]+\.[0-9]+\.[0-9]+(-[a-zA-Z0-9]+)?$ ]];
echo "Current tag is not a valid version. Exiting..."
exit 1
fi

# get commit hash for the current tag
# CURRENT_TAG_COMMIT=$(git rev-list -n 1 $CURRENT_TAG)

# get latest commit hash
# LATEST_COMMIT=$(git rev-parse HEAD)

# update variables in output files
for FILE_PATH in "${FILE_PATHS[@]}"
do
Expand Down

0 comments on commit 3aa281e

Please sign in to comment.