allow greater than or equal to v 4
This commit is contained in:
parent
6f2e155668
commit
e1999d826c
1 changed files with 2 additions and 1 deletions
|
@ -48,7 +48,8 @@ NODE_VERSION=$(node --version)
|
||||||
NODE_V_MINOR=$(echo $NODE_VERSION | cut -d "." -f 1-2)
|
NODE_V_MINOR=$(echo $NODE_VERSION | cut -d "." -f 1-2)
|
||||||
NODE_V_MAIN=$(echo $NODE_VERSION | cut -d "." -f 1)
|
NODE_V_MAIN=$(echo $NODE_VERSION | cut -d "." -f 1)
|
||||||
NODE_V_MAIN=${NODE_V_MAIN#"v"}
|
NODE_V_MAIN=${NODE_V_MAIN#"v"}
|
||||||
if [ ! $NODE_V_MINOR = "v0.10" ] && [ ! $NODE_V_MINOR = "v0.11" ] && [ ! $NODE_V_MINOR = "v0.12" ] && [ ! $NODE_V_MAIN -gt 4 ]; then
|
echo $NODE_V_MAIN
|
||||||
|
if [ ! $NODE_V_MINOR = "v0.10" ] && [ ! $NODE_V_MINOR = "v0.11" ] && [ ! $NODE_V_MINOR = "v0.12" ] && [ ! $NODE_V_MAIN -ge 4 ]; then
|
||||||
echo "You're running a wrong version of node. You're using $NODE_VERSION, we need node v0.10.x or higher" >&2
|
echo "You're running a wrong version of node. You're using $NODE_VERSION, we need node v0.10.x or higher" >&2
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in a new issue