Allow use within legacy node project

Status Fixed / completed
Maintainer reply None cached
Activity 3 comments · opened Feb 25, 2025 · closed Feb 25, 2025

If I run within a legacy node project with Node version less than 18, I get: Error: Claude Code requires Node.js version 18 or higher.

It would be great to be able to specify which Node binary to use with an environment variable. Currently I'm using this wrapper script to accomplish something similar:

#!/bin/sh

if [[ -n "$NODE_BINARY" ]]; then
	exec env PATH="$(dirname $NODE_BINARY):$PATH" claude "$@"
fi

exec claude "$@"

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗