Top 5 only.
This commit is contained in:
@@ -7,11 +7,11 @@ fi
|
||||
|
||||
node_version=$(node --version | grep --only-matching --extended-regexp 'v[0-9]+' | tr -d 'v')
|
||||
if [ -z "$node_version" ]; then
|
||||
echo "Unable to determine node version. Expected output of 'node --version' to contain a version, for example 'v12.13.1'"
|
||||
echo "Unable to determine node version. Expected output of 'node --version' to contain a version, for example 'v18.18.0'"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ $node_version -lt 12 ]; then
|
||||
echo "Node 12 or higher must be in the PATH"
|
||||
if [ $node_version -lt 18 ]; then
|
||||
echo "Node 18 or higher must be in the PATH"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user