Skip to content

Commit 3d72305

Browse files
committed
README: Add section describing how to start and connect to a socket server.
1 parent da88c8c commit 3d72305

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

README.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,19 @@ point. You can, however, change this behaviour by invoking such
103103
commands with a prefix argument. For instance: `C-u C-c C-v` will ask
104104
for the symbol you want to show the docstring for.
105105

106+
#### Starting and connecting to a socket server
107+
108+
For Leiningen, add this to your ~/.lein/profiles.clj or your project.clj:
109+
```:jvm-opts ["-Dclojure.server.repl={:port 5555 :accept clojure.core.server/repl}"]```
110+
111+
Then run `lein repl` from within your project directory, and `C-c M-c RET localhost RET 5555` from within Emacs.
112+
113+
For boot, export the environment variable BOOT_JVM_OPTIONS:
114+
```export BOOT_JVM_OPTIONS='-Dclojure.server.repl="{:port 5555 :accept clojure.core.server/repl}"'```
115+
116+
You can also start a socket server via the [Clojure CLI tools](https://clojure.org/guides/getting_started).
117+
Configuration options are described [here](https://dev.clojure.org/display/design/Socket+Server+REPL).
118+
106119
#### Caveats
107120

108121
Note that if you decide _NOT_ to use the socket repl, it is highly recommended

0 commit comments

Comments
 (0)