Those instructions assume Mac/Linux. Using environment variables like that doesn’t work on Windows.
I haven’t used Leiningen for years but you should be able to define :jvm-opts
inside project.clj
to this, and I’d suggest putting it in a separate profile such as :socket
so you can choose whether to start the Socket REPL or not:
# start regular nREPL / REPL only:
$ lein repl
# also start that socket REPL:
$ lein with-profile +socket repl