Abort osbash.sh if executed in Windows environment
The osbash host-side shell scripts do not work in a Windows environment. We create and support separate Windows batch files for that purpose. With this patch, users trying to run osbash in cygwin or mingw get a warning before the script aborts. Closes-Bug: #1625562 Change-Id: I60d245e45c80190645c652c2feb87b1dfd0bbc7f
This commit is contained in:
parent
e66208e795
commit
180e43354d
@ -8,6 +8,14 @@ trap 'kill -- -$$' SIGINT
|
||||
|
||||
TOP_DIR=$(cd "$(dirname "$0")" && pwd)
|
||||
|
||||
# Abort for Windows environment before sourcing scripts that may result
|
||||
# in other errors.
|
||||
if uname | grep -i -e "cygwin" -e "mingw"; then
|
||||
echo "Running osbash.sh in Windows is not supported. Instead, use the"
|
||||
echo "Windows batch scripts in the wbatch directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
source "$TOP_DIR/config/localrc"
|
||||
source "$TOP_DIR/config/paths"
|
||||
source "$CONFIG_DIR/openstack"
|
||||
|
Loading…
x
Reference in New Issue
Block a user