Add support for readlink on macOS
This commit is contained in:
11
deploy.sh
11
deploy.sh
@@ -6,7 +6,16 @@ DOCKER_NAME="blender_cloud"
|
|||||||
REMOTE_ROOT="/data/git/${PROJECT_NAME}"
|
REMOTE_ROOT="/data/git/${PROJECT_NAME}"
|
||||||
|
|
||||||
SSH="ssh -o ClearAllForwardings=yes cloud.blender.org"
|
SSH="ssh -o ClearAllForwardings=yes cloud.blender.org"
|
||||||
ROOT="$(dirname "$(readlink -f "$0")")"
|
|
||||||
|
# macOS does not support readlink -f, so we use greadlink instead
|
||||||
|
if [[ `uname` == 'Darwin' ]]; then
|
||||||
|
ash greadlink 2>/dev/null || { echo >&2 "Install greadlink using brew."; exit 1; }
|
||||||
|
readlink='grealink'
|
||||||
|
else
|
||||||
|
readlink='readlink'
|
||||||
|
fi
|
||||||
|
|
||||||
|
ROOT="$(dirname "$($readlink -f "$0")")"
|
||||||
cd ${ROOT}
|
cd ${ROOT}
|
||||||
|
|
||||||
# Check that we're on production branch.
|
# Check that we're on production branch.
|
||||||
|
Reference in New Issue
Block a user