[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/inf-clojure eec15c4 086/313: Accept cons pair for tcp conn
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/inf-clojure eec15c4 086/313: Accept cons pair for tcp connections (#34) |
Date: |
Wed, 11 Aug 2021 09:59:52 -0400 (EDT) |
branch: elpa/inf-clojure
commit eec15c43f9ea4deccf7cf64d329d75b1f9bcbdcd
Author: Mark Hinshaw <mahinshaw@gmail.com>
Commit: Bozhidar Batsov <bozhidar.batsov@gmail.com>
Accept cons pair for tcp connections (#34)
---
README.md | 7 +++++++
inf-clojure.el | 11 ++++++++---
2 files changed, 15 insertions(+), 3 deletions(-)
diff --git a/README.md b/README.md
index 6034312..5a44b86 100644
--- a/README.md
+++ b/README.md
@@ -46,6 +46,13 @@ Add the following to your Emacs config to enable
(add-hook 'clojure-mode-hook #'inf-clojure-minor-mode)
```
+`inf-clojure-program` is a custom variable that defines a program to run
+or the tcp socket to connect to when starting `inf-clojure`. By default
+this var is set to `lein repl`, which will start a repl via leiningen.
+However, it is possible to use a cons pair like `("localhost" . 5555)` to
+connect to a socket repl like the one provided with
[planck](http://planck-repl.org/),
+which can be started from the command line with `planck -n 5555`.
+
**Don't enable `inf-clojure-minor-mode` and `cider-mode` at the same
time. They have overlapping functionality and keybindings and the
result will be nothing short of havoc.**
diff --git a/inf-clojure.el b/inf-clojure.el
index 7490028..138e721 100644
--- a/inf-clojure.el
+++ b/inf-clojure.el
@@ -139,8 +139,11 @@ The following commands are available:
#'inf-clojure-completion-at-point))
(defcustom inf-clojure-program "lein repl"
- "Program name for invoking an inferior Clojure in Inferior Clojure mode."
- :type 'string
+ "Either a program name or a connection cons pair consisting of a host
+and port number (e.g. (\"localhost\" . 5555)), for invoking an inferior Clojure
+in Inferior Clojure mode."
+ :type '(choice (string)
+ (cons string integer))
:group 'inf-clojure)
(defcustom inf-clojure-load-command "(clojure.core/load-file \"%s\")\n"
@@ -322,7 +325,9 @@ of `inf-clojure-program'). Runs the hooks from
(if (not (comint-check-proc "*inf-clojure*"))
;; run the new process in the project's root when in a project folder
(let ((default-directory (inf-clojure-project-root))
- (cmdlist (split-string cmd)))
+ (cmdlist (if (consp cmd)
+ (list cmd)
+ (split-string cmd))))
(set-buffer (apply #'make-comint
"inf-clojure" (car cmdlist) nil (cdr cmdlist)))
(inf-clojure-mode)))
- [nongnu] elpa/inf-clojure f794889 073/313: Drop the mentions of Marmalade from the README, (continued)
- [nongnu] elpa/inf-clojure f794889 073/313: Drop the mentions of Marmalade from the README, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 54fe6de 074/313: Update the package description, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 7e86eaf 075/313: Update the copyright years, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure a9eb210 076/313: Release 1.4.0, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 2825eac 077/313: Bump the development version, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure aa93684 081/313: Convert a comment into docstring, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure a246bf3 083/313: Merge pull request #32 from slipset/customize-vars, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 3e7896a 084/313: [Fix #33] Add missing docstrings, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure aa81e31 085/313: Bump the clojure-mode and Emacs dependencies, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 98b530a 088/313: Refine a docstring, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure eec15c4 086/313: Accept cons pair for tcp connections (#34),
ELPA Syncer <=
- [nongnu] elpa/inf-clojure ee4369d 089/313: Fix typo in README, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 421b265 095/313: Add a command to display the inf-clojure version, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 166b077 098/313: Remove some obsolete code, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 6a4329b 100/313: Font-lock code in the REPL, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure d0f0ee8 103/313: Add a missing require, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 1d6260a 104/313: [Fix #29] Add a command to restart a REPL, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure a3306c9 137/313: Further fix arglists in lumo, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 59cd1f3 094/313: Add a changelog, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 2e20754 109/313: Support REPL types and Lumo, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 3041031 110/313: Fix typo in inf-clojure-*-cmd defcustoms, ELPA Syncer, 2021/08/11