mirror of openzeppelin-contracts
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
openzeppelin-contracts/scripts/set-max-old-space-size.sh

11 lines
338 B

#!/usr/bin/env sh
# This script sets the node `--max-old-space-size` to 8192 if it is not set already.
# All existing `NODE_OPTIONS` are retained as is.
export NODE_OPTIONS="${NODE_OPTIONS:-}"
if [ "${NODE_OPTIONS##*--max-old-space-size*}" = "$NODE_OPTIONS" ]; then
export NODE_OPTIONS="${NODE_OPTIONS} --max-old-space-size=8192"
fi