mirror of
https://github.com/coder/code-server.git
synced 2026-09-05 01:31:17 +02:00
Guard FORCE_NODE_VERSION in the version error path (#7983)
Installing on the wrong node version dies with "FORCE_NODE_VERSION: unbound variable" instead of explaining itself. The script runs under set -u and this is the one place the variable is read bare; the three other reads all default it.
This commit is contained in:
@@ -67,7 +67,7 @@ main() {
|
||||
|
||||
if [ "$major_node_version" -ne "${FORCE_NODE_VERSION:-24}" ]; then
|
||||
echo "ERROR: code-server currently requires node v24."
|
||||
if [ -n "$FORCE_NODE_VERSION" ]; then
|
||||
if [ -n "${FORCE_NODE_VERSION:-}" ]; then
|
||||
echo "However, you have overrided the version check to use v$FORCE_NODE_VERSION."
|
||||
fi
|
||||
echo "We have detected that you are on node v$major_node_version"
|
||||
|
||||
Reference in New Issue
Block a user