emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/inf-clojure b50102f 128/313: [Fix #58] Add a function to c


From: ELPA Syncer
Subject: [nongnu] elpa/inf-clojure b50102f 128/313: [Fix #58] Add a function to connect to remote socket repl (#68)
Date: Wed, 11 Aug 2021 10:00:00 -0400 (EDT)

branch: elpa/inf-clojure
commit b50102f6d1995d902b76b505d19bc8122086de03
Author: Erik Assum <erik@assum.net>
Commit: Bozhidar Batsov <bozhidar.batsov@gmail.com>

    [Fix #58] Add a function to connect to remote socket repl (#68)
---
 CHANGELOG.md   | 2 +-
 README.md      | 3 +++
 inf-clojure.el | 7 +++++++
 3 files changed, 11 insertions(+), 1 deletion(-)

diff --git a/CHANGELOG.md b/CHANGELOG.md
index 9555518..86ca252 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -3,7 +3,7 @@
 ## master (unreleased)
 
 ### New Features
-
+* [#57](https://github.com/clojure-emacs/inf-clojure/pull/68): Add 
`inf-clojure-connect`
 * [#66](https://github.com/clojure-emacs/inf-clojure/pull/56): Add Planck 
support.
 * [#51](https://github.com/clojure-emacs/inf-clojure/pull/51): Commands do not 
prompt by default anymore, unless they receive a non-nil prefix argument.
 * [#44](https://github.com/clojure-emacs/inf-clojure/pull/44): Add REPL types 
and Lumo support.
diff --git a/README.md b/README.md
index 7e2bf16..d1de492 100644
--- a/README.md
+++ b/README.md
@@ -74,6 +74,9 @@ The REPL commands don't prompt by default but a prefix 
argument will invert
 this. For instance: `C-u C-c C-v` will ask for the symbol you want to show the
 docstring for.
 
+You can use `M-x inf-clojure-connect` to connect to a running socket-repl.
+You will be prompted for host and port.
+
 ## REPL Type
 
 An `inf-clojure` REPL can be of different types: Clojure, ClojureScript, Lumo 
and Planck are all potentially valid options.
diff --git a/inf-clojure.el b/inf-clojure.el
index b499192..5057c6c 100644
--- a/inf-clojure.el
+++ b/inf-clojure.el
@@ -467,6 +467,13 @@ of `inf-clojure-*-cmd').  Runs the hooks from
       (pop-to-buffer-same-window "*inf-clojure*")
     (pop-to-buffer "*inf-clojure*")))
 
+;;;###autoload
+(defun inf-clojure-connect (host port)
+  "Connect to a running socket-repl via `inf-clojure'.
+HOST is the host the process is running on, PORT is where it's listening."
+  (interactive "shost: \nnport: ")
+  (inf-clojure (cons host port)))
+
 (defun inf-clojure-eval-region (start end &optional and-go)
   "Send the current region to the inferior Clojure process.
 Prefix argument AND-GO means switch to the Clojure buffer afterwards."



reply via email to

[Prev in Thread] Current Thread [Next in Thread]