Skip to content

Commit d6a875b

Browse files
alexander-yakushevbbatsov
authored andcommitted
Remove Boot support
1 parent c508490 commit d6a875b

File tree

9 files changed

+25
-193
lines changed

9 files changed

+25
-193
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
### Changes
1212

1313
- [#3782](https://github.com/clojure-emacs/cider/issues/3782): **(Breaking)** Drop official support for Emacs 26.
14+
- [#3812](https://github.com/clojure-emacs/cider/issues/3812): **(Breaking)** Remove support for Boot.
1415
- [#3793](https://github.com/clojure-emacs/cider/issues/3793): **(Breaking)** Remove features that relied on printed exception parsing:
1516
- `cider-stacktrace-analyze-string` and `cider-stacktrace-analyze-at-point` functions.
1617
- Automatic stacktrace parsing in log viewer.

README.md

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ install CIDER with the following command:
6161

6262
### Launch an nREPL server and client from Emacs
6363

64-
Simply open in Emacs a file belonging to your `lein`, `tools.deps` or `boot` project (like
64+
Simply open in Emacs a file belonging to your `lein` or `tools.deps` project (like
6565
`foo.clj`) and type <kbd>M-x</kbd> `cider-jack-in`. This will start an nREPL
6666
server with all the project dependencies loaded in and CIDER will automatically
6767
connect to it.
@@ -82,12 +82,6 @@ You can go to your project's directory in a terminal and type there
8282
$ lein repl
8383
```
8484

85-
Or with Boot:
86-
87-
```
88-
$ boot repl -s wait
89-
```
90-
9185
Alternatively you can start nREPL either manually or by the facilities provided
9286
by your project's build tool (`tools.deps`, Gradle, Maven, etc).
9387

cider.el

Lines changed: 8 additions & 57 deletions
Original file line numberDiff line numberDiff line change
@@ -289,7 +289,9 @@ By default we favor the project-specific shadow-cljs over the system-wide."
289289
:package-version '(cider . "1.14.0"))
290290

291291
(make-obsolete-variable 'cider-lein-global-options 'cider-lein-parameters "1.8.0")
292-
(make-obsolete-variable 'cider-boot-global-options 'cider-boot-parameters "1.8.0")
292+
(make-obsolete-variable 'cider-boot-command nil "1.8.0")
293+
(make-obsolete-variable 'cider-boot-parameters nil "1.8.0")
294+
(make-obsolete-variable 'cider-boot-global-options nil "1.8.0")
293295
(make-obsolete-variable 'cider-clojure-cli-global-options 'cider-clojure-cli-parameters "1.8.0")
294296
(make-obsolete-variable 'cider-shadow-cljs-global-options 'cider-shadow-cljs-parameters "1.8.0")
295297
(make-obsolete-variable 'cider-gradle-global-options 'cider-gradle-parameters "1.8.0")
@@ -300,7 +302,7 @@ By default we favor the project-specific shadow-cljs over the system-wide."
300302
(if (executable-find "clojure") 'clojure-cli 'lein)
301303
"The default tool to use when doing `cider-jack-in' outside a project.
302304
This value will only be consulted when no identifying file types, i.e.
303-
project.clj for leiningen or build.boot for boot, could be found.
305+
project.clj for leiningen or deps.edn for clojure-cli, could be found.
304306
305307
As the Clojure CLI is bundled with Clojure itself, it's the default.
306308
In the absence of the Clojure CLI (e.g. on Windows), we fallback
@@ -320,7 +322,7 @@ to Leiningen."
320322
nil
321323
"Allow choosing a build system when there are many.
322324
When there are project markers from multiple build systems (e.g. lein and
323-
boot) the user is prompted to select one of them. When non-nil, this
325+
clojure-cli) the user is prompted to select one of them. When non-nil, this
324326
variable will suppress this behavior and will select whatever build system
325327
is indicated by the variable if present. Note, this is only when CIDER
326328
cannot decide which of many build systems to use and will never override a
@@ -432,7 +434,6 @@ The plist supports the following keys
432434
"Determine the command `cider-jack-in' needs to invoke for the PROJECT-TYPE."
433435
(pcase project-type
434436
('lein cider-lein-command)
435-
('boot cider-boot-command)
436437
('clojure-cli cider-clojure-cli-command)
437438
('babashka cider-babashka-command)
438439
('shadow-cljs cider-shadow-cljs-command)
@@ -477,7 +478,6 @@ Throws an error if PROJECT-TYPE is unknown."
477478
" "
478479
r)
479480
r)))
480-
('boot (cider--resolve-command cider-boot-command))
481481
('clojure-cli (if (and cider-enrich-classpath
482482
(not (eq system-type 'windows-nt))
483483
(executable-find (cider--get-enrich-classpath-clojure-cli-script)))
@@ -510,7 +510,6 @@ Throws an error if PROJECT-TYPE is unknown."
510510
"Determine the command line options for `cider-jack-in' for the PROJECT-TYPE."
511511
(pcase project-type
512512
('lein cider-lein-global-options)
513-
('boot cider-boot-global-options)
514513
('clojure-cli cider-clojure-cli-global-options)
515514
('babashka cider-babashka-global-options)
516515
('shadow-cljs cider-shadow-cljs-global-options)
@@ -527,7 +526,6 @@ Throws an error if PROJECT-TYPE is unknown."
527526
;; Please be careful when changing them.
528527
(pcase project-type
529528
('lein cider-lein-parameters)
530-
('boot cider-boot-parameters)
531529
('clojure-cli cider-clojure-cli-parameters)
532530
('babashka cider-babashka-parameters)
533531
('shadow-cljs cider-shadow-cljs-parameters)
@@ -545,7 +543,7 @@ Throws an error if PROJECT-TYPE is unknown."
545543
(defcustom cider-injected-nrepl-version "1.3.1"
546544
"The version of nREPL injected on jack-in.
547545
We inject the newest known version of nREPL just in case
548-
your version of Boot or Leiningen is bundling an older one."
546+
your version of Leiningen is bundling an older one."
549547
:type 'string
550548
:package-version '(cider . "1.2.0")
551549
:safe #'stringp)
@@ -692,45 +690,13 @@ returned by this function only contains strings."
692690
(car spec)
693691
spec)))))
694692

695-
(defun cider--list-as-boot-artifact (list)
696-
"Return a boot artifact string described by the elements of LIST.
697-
LIST should have the form (ARTIFACT-NAME ARTIFACT-VERSION). The returned
698-
string is quoted for passing as argument to an inferior shell."
699-
(concat "-d " (shell-quote-argument (format "%s:%s" (car list) (cadr list)))))
700-
701693
(defun cider--jack-in-required-dependencies ()
702694
"Returns the required CIDER deps.
703695
They are normally added to `cider-jack-in-dependencies',
704696
unless it's a Lein project."
705697
`(("nrepl/nrepl" ,cider-injected-nrepl-version)
706698
("cider/cider-nrepl" ,cider-injected-middleware-version)))
707699

708-
(defun cider-boot-dependencies (dependencies)
709-
"Return a list of boot artifact strings created from DEPENDENCIES."
710-
(concat (mapconcat #'cider--list-as-boot-artifact dependencies " ")
711-
(unless (seq-empty-p dependencies) " ")))
712-
713-
(defun cider-boot-middleware-task (params middlewares)
714-
"Create a command to add MIDDLEWARES with corresponding PARAMS."
715-
(concat "cider.tasks/add-middleware "
716-
(mapconcat (lambda (middleware)
717-
(format "-m %s" (shell-quote-argument middleware)))
718-
middlewares
719-
" ")
720-
" " params))
721-
722-
(defun cider-boot-jack-in-dependencies (global-opts params dependencies middlewares)
723-
"Create boot jack-in dependencies.
724-
Does so by concatenating GLOBAL-OPTS, DEPENDENCIES,
725-
and MIDDLEWARES. PARAMS and MIDDLEWARES are passed on to
726-
`cider-boot-middleware-task` before concatenating and DEPENDENCIES
727-
are passed on to `cider-boot-dependencies`."
728-
(concat global-opts
729-
(unless (seq-empty-p global-opts) " ")
730-
"-i \"(require 'cider.tasks)\" " ;; Note the space at the end here
731-
(cider-boot-dependencies (append (cider--jack-in-required-dependencies) dependencies))
732-
(cider-boot-middleware-task params middlewares)))
733-
734700
(defun cider--gradle-dependency-notation (dependency)
735701
"Returns Gradle's GAV dependency syntax.
736702
For a \"group/artifact\" \"version\") DEPENDENCY list
@@ -959,8 +925,8 @@ See also `cider-jack-in-auto-inject-clojure'."
959925
These are set in `cider-jack-in-dependencies', `cider-jack-in-lein-plugins'
960926
and `cider-jack-in-nrepl-middlewares' are injected from the CLI according
961927
to the used PROJECT-TYPE, and COMMAND if provided. Eliminates the need for
962-
hacking profiles.clj or the boot script for supporting CIDER with its nREPL
963-
middleware and dependencies."
928+
hacking profiles.clj for supporting CIDER with its nREPL middleware and
929+
dependencies."
964930
(pcase project-type
965931
('lein (cider-lein-jack-in-dependencies
966932
global-opts
@@ -970,12 +936,6 @@ middleware and dependencies."
970936
cider-jack-in-dependencies-exclusions
971937
(cider-jack-in-normalized-lein-plugins)
972938
cider-jack-in-lein-middlewares))
973-
('boot (cider-boot-jack-in-dependencies
974-
global-opts
975-
params
976-
(cider-add-clojure-dependencies-maybe
977-
cider-jack-in-dependencies)
978-
(cider-jack-in-normalized-nrepl-middlewares)))
979939
('clojure-cli (cider-clojure-cli-jack-in-dependencies
980940
global-opts
981941
params
@@ -1057,12 +1017,6 @@ Generally you should not disable this unless you run into some faulty check."
10571017
(unless (cider-library-present-p "weasel.repl.server")
10581018
(user-error "Weasel in not available. Please check https://docs.cider.mx/cider/basics/clojurescript/#browser-connected-clojurescript-repl for details")))
10591019

1060-
(defun cider-check-boot-requirements ()
1061-
"Check whether we can start a Boot ClojureScript REPL."
1062-
(cider-verify-piggieback-is-present)
1063-
(unless (cider-library-present-p "adzerk.boot-cljs-repl")
1064-
(user-error "The Boot ClojureScript REPL is not available. Please check https://github.com/adzerk-oss/boot-cljs-repl/blob/master/README.md for details")))
1065-
10661020
(defun cider-check-krell-requirements ()
10671021
"Check whether we can start a Krell ClojureScript REPL."
10681022
(cider-verify-piggieback-is-present)
@@ -1223,8 +1177,6 @@ The supplied string will be wrapped in a do form if needed."
12231177
cider-check-node-requirements)
12241178
(weasel "(do (require 'weasel.repl.websocket) (cider.piggieback/cljs-repl (weasel.repl.websocket/repl-env :ip \"127.0.0.1\" :port 9001)))"
12251179
cider-check-weasel-requirements)
1226-
(boot "(do (require 'adzerk.boot-cljs-repl) (adzerk.boot-cljs-repl/start-repl))"
1227-
cider-check-boot-requirements)
12281180
(shadow cider-shadow-cljs-init-form cider-check-shadow-cljs-requirements)
12291181
(shadow-select cider-shadow-select-cljs-init-form cider-check-shadow-cljs-requirements)
12301182
(krell "(require '[clojure.edn :as edn]
@@ -2072,7 +2024,6 @@ Search for lein or java processes including nrepl.command nREPL."
20722024
PROJECT-DIR defaults to current project."
20732025
(let* ((default-directory (or project-dir (clojure-project-dir (cider-current-dir))))
20742026
(build-files '((lein . "project.clj")
2075-
(boot . "build.boot")
20762027
(clojure-cli . "deps.edn")
20772028
(babashka . "bb.edn")
20782029
(shadow-cljs . "shadow-cljs.edn")

doc/modules/ROOT/pages/basics/installation.adoc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@ CIDER officially supports Emacs 27.1+, Java 8+, and Clojure(Script) 1.10+. If
1616
you need to work with earlier versions, check
1717
xref:about/compatibility.adoc#compatibility-matrix[compatibility matrix].
1818

19-
You'll also need a recent version of either the Clojure CLI tools or your
20-
favorite build tool (Leiningen, Boot, or Gradle) to be able to start CIDER via
21-
`cider-jack-in`. Generally it's a good idea to use the latest stable versions.
19+
You'll also need a recent version of your favorite build tool (Clojure CLI,
20+
Leiningen, or Gradle) to be able to start CIDER via `cider-jack-in`. Generally
21+
it's a good idea to use the latest stable versions.
2222

2323
== Installation via package.el
2424

doc/modules/ROOT/pages/cljs/other_repls.adoc

Lines changed: 0 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -48,45 +48,6 @@ documentation lookup, the namespace browser, and macroexpansion).
4848

4949
TIP: For more information on Weasel you should consult its https://github.com/nrepl/weasel/blob/master/README.md[documentation].
5050

51-
== Boot ClojureScript REPL
52-
53-
`boot-cljs` is another browser-connected ClojureScript REPL, that's targeting the Boot build tool.
54-
Internally, it's powered by Weasel. Let's go over the steps required to use it.
55-
56-
. Add this to your dependencies in `build.boot`:
57-
+
58-
[source,clojure]
59-
----
60-
[adzerk/boot-cljs "X.Y.Z" :scope "test"]
61-
[adzerk/boot-cljs-repl "X.Y.Z" :scope "test"]
62-
[pandeiro/boot-http "X.Y.Z" :scope "test"]
63-
[weasel "0.7.1" :scope "test"]
64-
[cider/piggieback "0.5.3" :scope "test"] ; not needed for cider-jack-in-cljs
65-
----
66-
+
67-
and this at the end of `build.boot`:
68-
+
69-
[source,clojure]
70-
----
71-
(require
72-
'[adzerk.boot-cljs :refer [cljs]]
73-
'[adzerk.boot-cljs-repl :refer [cljs-repl]]
74-
'[pandeiro.boot-http :refer [serve]])
75-
76-
(deftask dev []
77-
(comp (serve)
78-
(watch)
79-
(cljs-repl) ; order is important!!
80-
(cljs)))
81-
----
82-
+
83-
. Type kbd:[M-x] `customize-variable` kbd:[RET] `cider-boot-parameters`
84-
and insert `dev`.
85-
. Open a file in your project and type kbd:[M-x] `cider-jack-in-cljs`.
86-
. Connect to the running server with your browser. The address is printed on the terminal, but it's probably `+http://localhost:3000+`.
87-
88-
For more information visit https://github.com/adzerk-oss/boot-cljs-repl[boot-cljs-repl].
89-
9051
== nbb (node.js babashka)
9152

9253
CIDER has built-in support for `nbb`. You can either jack in to an nbb project with `M-x clojure-jack-in-cljs`.

doc/modules/ROOT/pages/cljs/up_and_running.adoc

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,13 @@ to connect to an already running nREPL server using
1919
=== Manual Piggieback Setup
2020

2121
To setup piggieback, add the following dependencies to your project
22-
(`project.clj` in a Leiningen based project or `build.boot` in a Boot
23-
project or `deps.edn`):
22+
(`project.clj` or `deps.edn`):
2423

2524
[source,clojure]
2625
----
2726
;; use whatever are the most recent versions here
28-
[cider/piggieback "0.5.3"]
29-
[org.clojure/clojure "1.11.1"]
27+
[cider/piggieback "0.6.0"]
28+
[org.clojure/clojure "1.12.0"]
3029
----
3130

3231
as well as `piggieback` nREPL middleware:
@@ -38,14 +37,6 @@ in `project.clj`:
3837
:repl-options {:nrepl-middleware [cider.piggieback/wrap-cljs-repl]}
3938
----
4039

41-
or in `build.boot`:
42-
43-
[source,clojure]
44-
----
45-
(task-options!
46-
repl {:middleware '[cider.piggieback/wrap-cljs-repl]})
47-
----
48-
4940
or in `deps.edn`:
5041

5142
[source,clojure]

doc/modules/ROOT/pages/troubleshooting.adoc

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -161,8 +161,8 @@ least what's being required).
161161

162162
=== Warning saying you have to use newer nREPL
163163

164-
CIDER currently requires at least nREPL 0.6 to work properly. As nREPL comes
165-
bundled with Leiningen and Boot, from time to time you might have to override the
164+
CIDER currently requires at least nREPL 1.0 to work properly. As nREPL comes
165+
bundled with Leiningen, from time to time you might have to override the
166166
version supplied by them (e.g. if you're forced to use an older version of
167167
Leiningen or there's no release bundling the required nREPL version yet). Leiningen
168168
users can add this to their `profiles.clj` to force the proper dependency:
@@ -172,8 +172,6 @@ users can add this to their `profiles.clj` to force the proper dependency:
172172
{:repl {:dependencies [[nrepl/nrepl "x.y.z"]]}}
173173
----
174174

175-
The procedure is pretty similar for Boot.
176-
177175
IMPORTANT: Make sure you add the newer nREPL dependency to the `:dependencies` key instead
178176
of `:plugins` (where the `cider-nrepl` Lein plugin resides). That's a pretty common
179177
mistake.
@@ -230,7 +228,6 @@ in the "Middleware Setup" section.
230228
* Do `C-h v cider-inject-dependencies-at-jack-in`, and check that this variable is non-nil.
231229
* Make sure your project depends on at least Clojure `1.7.0`.
232230
* If you use Leiningen, make sure your `lein --version` is at least `2.9.0`.
233-
* If you use Boot and you've changed `cider-boot-parameters`, that's probably the cause.
234231

235232
If the above doesn't work, you can try specifying the cider-nrepl middleware
236233
manually, as per the
@@ -242,8 +239,8 @@ in the "Middleware Setup" section.
242239
This means you're manually adding the cider-nrepl middleware in your project,
243240
but you shouldn't do that because `cider-jack-in` already does that for
244241
you. Look into the following files, and ensure you've removed all references to
245-
`cider-nrepl` and `nrepl`: `project.clj`, `build.boot`,
246-
`~/.lein/profiles.clj` and `~/.boot/profile.boot`.
242+
`cider-nrepl` and `nrepl`: `project.clj`, `deps.edn`,
243+
`~/.lein/profiles.clj` and `~/.clojure/deps.edn`.
247244

248245
=== I get some error related to refactor-nrepl on startup
249246

doc/modules/ROOT/pages/usage/code_completion.adoc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -198,9 +198,9 @@ keys to cancel the prompt by customizing:
198198

199199
Sometimes, the completion fails to recognize new classes that came with
200200
dependencies that were loaded dynamically after the REPL was started (e.g. via
201-
Boot). Executing `M-x cider-completion-flush-caches` (or going through the menu
202-
`+CIDER Interaction->Misc->Flush completion cache+`) forces the completion backend
203-
to re-read all classes it can find on the classpath.
201+
Clojure 1.12 `add-lib`). Executing `M-x cider-completion-flush-caches` (or going
202+
through the menu `+CIDER Interaction->Misc->Flush completion cache+`) forces the
203+
completion backend to re-read all classes it can find on the classpath.
204204

205205
== Implementation Details
206206

0 commit comments

Comments
 (0)