Fix build_rust_sdk.sh script to work on linux (#3291)

A few linux distributions don't have `gdate`, but I think they should
all have `date`.
This commit is contained in:
Erik Johnston
2024-08-09 15:04:49 +01:00
committed by GitHub
parent 9b061ca798
commit 95d6a80ae6

View File

@@ -7,7 +7,12 @@ set -e
read -p "Do you want to build the Rust SDK from local source (yes/no) default to yes? " buildLocal
buildLocal=${buildLocal:-yes}
date=$(gdate +%Y%m%d%H%M%S)
if [[ "$OSTYPE" == "linux-gnu"* ]]; then
date=$(date +%Y%m%d%H%M%S)
else
date=$(gdate +%Y%m%d%H%M%S)
fi
elementPwd=$(pwd)
# Ask for the Rust SDK local source path