[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/inf-clojure 8c27b06 177/313: Introduce the tools.deps proj
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/inf-clojure 8c27b06 177/313: Introduce the tools.deps project type |
Date: |
Wed, 11 Aug 2021 10:00:11 -0400 (EDT) |
branch: elpa/inf-clojure
commit 8c27b0603971e603db686131c3e411a02579501d
Author: Andrea Richiardi <a.richiardi.work@gmail.com>
Commit: Bozhidar Batsov <bozhidar.batsov@gmail.com>
Introduce the tools.deps project type
The new inf-clojure-tools-deps-cmd will be used when the deps.edn file is
going
to be detected in the project root.
---
CHANGELOG.md | 1 +
README.md | 12 ++++++------
inf-clojure.el | 17 ++++++++++++++++-
3 files changed, 23 insertions(+), 7 deletions(-)
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 698edb0..b023e55 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -12,6 +12,7 @@
### New Features
* [#114](https://github.com/clojure-emacs/inf-clojure/pull/114): Introduce
`inf-clojure-project-type` defcustom.
+* [#117](https://github.com/clojure-emacs/inf-clojure/pull/117): Introduce
`tools.deps` project type and `inf-clojure-tools-deps-cmd`.
## 2.0.1 (2017-05-18)
diff --git a/README.md b/README.md
index c3963cb..f528b1c 100644
--- a/README.md
+++ b/README.md
@@ -71,12 +71,12 @@ Just invoke `M-x inf-clojure` or press `C-c C-z` within a
Clojure source file.
This will start a REPL process for the current project and you can start
interacting with it.
-`inf-clojure` has several custom variables which control the command
-used to start a REPL for particular project type - `inf-clojure-lein-cmd`,
-`inf-clojure-boot-cmd` and `inf-clojure-generic-cmd`.
-The `inf-clojure-project-type` can force a particular project type, skipping
-the project detection, which can be useful for projects that don't have
-standard layouts.
+`inf-clojure` has several custom variables which control the command used to
+start a REPL for particular project type - `inf-clojure-lein-cmd`,
+`inf-clojure-boot-cmd`, `inf-clojure-tools-deps-cmd` and
+`inf-clojure-generic-cmd`. The `inf-clojure-project-type` can force a
+particular project type, skipping the project detection, which can be useful
+for projects that don't have standard layouts.
By default all those variables are set to strings (e.g. `lein repl`).
However, it is possible to use a cons pair like `("localhost" . 5555)`
diff --git a/inf-clojure.el b/inf-clojure.el
index ecfde28..3bd4bfe 100644
--- a/inf-clojure.el
+++ b/inf-clojure.el
@@ -225,6 +225,19 @@ often connecting to a remote REPL process."
:safe #'inf-clojure--endpoint-p
:package-version '(inf-clojure . "2.0.0"))
+(defcustom inf-clojure-tools-deps-cmd "clj"
+ "The command used to start a Clojure REPL for tools.deps projects.
+
+Alternatively you can specify a TCP connection cons pair, instead
+of command, consisting of a host and port
+number (e.g. (\"localhost\" . 5555)). That's useful if you're
+often connecting to a remote REPL process."
+ :type '(choice (string)
+ (cons string integer))
+ :risky #'stringp
+ :safe #'inf-clojure--endpoint-p
+ :package-version '(inf-clojure . "2.1.0"))
+
(defcustom inf-clojure-generic-cmd "lein repl"
"The command used to start a Clojure REPL outside Lein/Boot projects.
@@ -503,7 +516,7 @@ to continue it."
(t str)))
(defvar inf-clojure-project-root-files
- '("project.clj" "build.boot")
+ '("project.clj" "build.boot" "deps.edn")
"A list of files that can be considered project markers.")
(defun inf-clojure-project-root ()
@@ -523,6 +536,7 @@ Fallback to `default-directory.' if not within a project."
(let ((default-directory (inf-clojure-project-root)))
(cond ((file-exists-p "project.clj") "lein")
((file-exists-p "build.boot") "boot")
+ ((file-exists-p "deps.edn") "tools.deps")
(t "generic")))))
(defun inf-clojure-cmd (project-type)
@@ -530,6 +544,7 @@ Fallback to `default-directory.' if not within a project."
(pcase project-type
("lein" inf-clojure-lein-cmd)
("boot" inf-clojure-boot-cmd)
+ ("tools.deps" inf-clojure-tools-deps-cmd)
(_ inf-clojure-generic-cmd)))
(defun inf-clojure-clear-repl-buffer ()
- [nongnu] elpa/inf-clojure 4e96e93 147/313: Fix a bug causing read to output for expression, (continued)
- [nongnu] elpa/inf-clojure 4e96e93 147/313: Fix a bug causing read to output for expression, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 9ba23b0 149/313: Wrap a long line, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 956b22e 148/313: Release 2.0.1, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 74e8423 150/313: Fix get-completions for lumo (#81), ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 9fa8f37 153/313: Disable pretty print when fetching lumo arglists, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure f666f60 154/313: [Fix #79] Disable coloring for the boot repl (#82), ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 1a71b5e 163/313: Rephrase process logging description a bit, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure ee38fc3 164/313: [Fix #96] Use inf-clojure--send-string instead of comint-proc-query, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 7493ed8 166/313: Set inf-clojure-*-cmd :risky and :safe properties, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure b048358 173/313: Add expression break chars and prevent completions for numbers (#110), ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 8c27b06 177/313: Introduce the tools.deps project type,
ELPA Syncer <=
- [nongnu] elpa/inf-clojure 5c8f590 179/313: [Fix #116] Set inf-clojure-buffer REPL type on detect, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 7b2fcd7 184/313: Revive inf-clojure-apropos, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 8baa7ad 185/313: Correct inf-clojure-apropos key binding, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure d3c0d4f 187/313: Avoid throwing an error for frequent operations like completion, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 630471b 194/313: Update CHANGELOG.md, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure c3217c3 200/313: Skip sanitation of comments, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 9b77479 207/313: Set inf-clojure-tools-deps-cmd to "clojure" (#144), ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 58150d7 256/313: Improve some wording in the README, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure f63c609 252/313: Fix a typo, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure b5e915c 204/313: Travis test like in cider, ELPA Syncer, 2021/08/11