Commit Graph

112 Commits

Author SHA1 Message Date
SpacemacsBot 19bde126a5
[bot] documentation_updates (#15271)
Co-authored-by: SpacemacsBot <not@an.actual.email.beep.boop>
2022-01-15 02:29:19 +00:00
John Practicalli 84033e168d [clojure] add kaocha-runner as optional package
Add kaocha-runner.el to the Clojure layer to enable running the kaocha test
runner from Emacs Cider

Kaocha runner added to the layer via the clojure-enable-kaocha-runner variable

Add key bindings to call Kaocha runner
2022-01-14 18:03:53 +01:00
Maximilian Wolff 9d7090cee3
[clojure] Add instructions to disable lsp server support
Standard LSP support auto-activates the server
if LSP layer is loaded. I have now added instructions
to explicitly disable this behaviour if someone wants
to work in LSP in one layer but only with CIDER in
clojure.
2020-12-18 23:35:40 +01:00
John Practicalli Stevenson f9123b1cc5 [clojure] add namespace eval and reload key bindings
Add key binding to evaluate the current namespace form (very useful when
starting CIDER as it loads in clojure.core to enable the cider-clojure-docs
functions to work)

Add keybinding to reload all namespaces into the REPL process

Adjusted key bindings to be lower case under `en` sub-menu.
2020-11-24 21:46:23 +01:00
Maximilian Wolff 6d39cd5548
[clojure] Add lsp server support 2020-11-24 21:35:31 +01:00
John Practicalli Stevenson d929079f28 [clojure] add cider-inspect key bindings
Add cider inspect key bindings missing from Spacemacs
2020-11-21 07:26:20 +01:00
John Practicalli Stevenson f2c075b673 [clojure] key binding for cider eval list around point
New command added to CIDER in version 0.26 to evaluate the list around the
current point, different to evaluate sexp around point which also evaluates
symbols.

https://github.com/clojure-emacs/cider/pull/2881
2020-10-01 12:29:35 +02:00
emacspace 0fda75c688 documentation formatting: Fri Aug 28 21:26:14 UTC 2020 2020-08-28 23:41:29 +02:00
romain.gautier@nimamoh.net ba982822c6
Replace deprecated clojure-cheatsheet with helm-cider 2020-08-09 23:59:34 +02:00
Maximilian Wolff d65c091656
[clojure] Document new automatic namespace switching in REPL 2020-08-09 11:57:58 +02:00
John Practicalli Stevenson 5f7e56fecc [clojure] refactor namespace key bindings
Add key bindings to refactor namespace forms for existing functions in CIDER.

"ran" 'clojure-insert-ns-form
"raN" 'clojure-insert-ns-form-at-point
"run" 'clojure-update-ns
2020-07-12 21:01:57 +02:00
刘冲 aaaf1c89a2 Update README.org of clojure layer to remove redundant `linting via...` 2020-05-08 23:18:03 +02:00
John Practicalli Stevenson 587ae8ebac
[clojure] Pretty print evaluation keybindings
Show results of evaluating Clojure code in the same format they would be written
in the source code.  This is especially useful for results that are
collections and nested collections.

Pretty print results as a comment.
2020-03-27 21:02:06 +01:00
jr0cket af2d7e320e
[clojure] keybindings for browsing clojure specs
Browse a specific clojure spec or browse all specs in a project.
2020-03-12 20:54:09 +01:00
jr0cket 2a17228ef8
[clojure] Add goto end of line eval sexp
Clojure (CIDER) is missing the incredibly useful function that jumps to the end
of the line and evaluates the last s-expression.

This function is in Emacs Lisp major mode under `SPC m e $` and `SPC m e l`

The function `spacemacs/cider-eval-sexp-end-of-line` is a copy of
`lisp-state-eval-end-of-line` with the last line replaced to call the equivalent
cider function, `cider-eval-last-sexp`.

The same keybindings are added to the Clojure layer as used for elisp.

The keybindings follow the Spacemacs convention for evaluation, as defined in
https://github.com/syl20bnr/spacemacs/blob/master/doc/CONVENTIONS.org#evaluation

Resolves #4124
2020-03-01 00:14:32 +01:00
emacspace 546f626be9
documentation formatting: Sat Feb 22 10:39:46 UTC 2020 2020-02-22 11:44:35 +01:00
jr0cket 79842c89cf [Clojure] Sesman and missing eval / format keybindings
Added keybindings for the Sesman REPL session management commands to the Clojure
layer, following the Spacemacs keybinding conventions.
https://docs.cider.mx/cider/0.23/usage/managing_connections.html

Sesman has been a part of CIDER for many versions now and provides session
management for nREPL connections (in fact any connections).

Sesman keybinds are placed in the `SPC m c` menu, providing a cleaner separation
between sending code to the repl and session management.

See issue #12593 and PR #13140 which covers the background for the design of
these additional keybindings.

Formatting the region and defun keybinds have been added, along with formatting
for edn files.  Moved to `=` menu to match Spacemacs convention.

Evaluation up to point keybinding has also been added.

Documentation in the README has been updated to complete the description of the
existing Clojure layer, as well as including details specific to the new
keybindings.
2020-02-01 15:33:04 -05:00
syl20bnr 52d1b0f323 Revert "[clojure] Add sesman keybindings"
This breaks Spacemacs convention:
https://github.com/syl20bnr/spacemacs/blob/develop/doc/CONVENTIONS.org#repls

Need to add session management under an unused prefix, I suggest SPC m S

This reverts commit e47494229b.
2020-01-25 10:17:08 -05:00
emacspace ff5b3ae291 documentation formatting: Thu Jan 23 11:14:51 UTC 2020 2020-01-23 12:18:03 +01:00
duianto 0b023bd764 [clojure] Fix typos 2020-01-23 12:10:37 +01:00
jr0cket e47494229b [clojure] Add sesman keybindings
Add Spacemacs keybindings to the Clojure layer for all the sesman functions.

Sesman has been a part of CIDER for many versions now and provides session
management for nREPL connections (in fact any connections).

Several keybindings relating to the use of a specific repl been migrated the
`e` evaluation menu and `es` sent-to-repl-buffer sub-menu, providing a cleaner
separation between repl connection and session management and interacting with a
specific repl.

Updated layer documentation and keybindings in README.org file.
Added changes to CHANGELOG.develop

Resolves #12593
2020-01-23 11:43:38 +01:00
jaremko 247830ab40 fix links 2019-11-10 16:13:13 +02:00
Didier A 58dcd6320b [clojure] Added support for joker linter and having mutliple active linters
The variable clojure-enable-linters can now be set to a list of linters:

'(clj-kondo joker)
  or
'(joker squiggly)
  or any other combination of the available linters.

In which case, all linters in the list will be active if they are
available to be. In that flycheck is configured so that each linter
in the list has as next-checker the next linter in the list.

The variable can also now be set to:

'joker

If only the newly added joker linter should be used.

This will pull down flycheck-joker and add Joker as a checker for
Clojure modes.

--

Implementation Details

The way it works is that for each Clojure linting mode, clj, cljc,
cljs and edn, a primary linter is chosen based on the order the
user specifies in clojure-enable-linters which support that mode.
It is made the primary linter for flycheck to use by being promoted
to the front of the flycheck-checkers list. All other linters specified
by the user which the mode also supports get added to it as a
next-checker.

Tested with clj-kondo, joker and squiggly. The only issue I saw was that
the way flycheck-clojure works, and the way I currently have setup the
logic for multiple checkers mean that we can't add to a mode multiple
checkers for the same linter. flycheck-clojure has eastwood, kibit and
core.typed. If you have it configured to use eastwood linter, then it
will all work, as eastwood gets added as the next-checker. But if you
have it disabled in flycheck-clojure, there won't be any
flycheck-clojure linters to activate. I'm not sure as of now how to best
support that. Ideally, we would not clubber linters into a single packge
like that, and so the layer would have instead of squiggly: eastwood,
kibit, core.typed. But that's not how flycheck-clojure works. Future
commit might be able to do something smarter about this.
2019-10-20 00:23:58 +02:00
Jonathan Chen a326913a9e docs: fix spelling 2019-09-11 18:40:40 +02:00
emacspace 1299f262ca documentation formatting: Sun Sep 1 21:18:40 UTC 2019 2019-09-01 23:08:29 -04:00
John Stevenson 7afa22e1d0 [Clojure] Update Clojure layer linter documentation
Enhancement to Clojure layer documentation for the clj-kondo linter added via
pul request #12611

Moved instructions to install section as clj-kondo and squiqgly can be added as
Clojure layer variables, just like clj-refactor and sayid.

Changed the install instructions to make them specific and to use clojure layer
variables, which is consistent with other Clojure layer options.

Elaborated on the install instructions to clarify requirements, constraints and
recommended linting tool.

Added credits to the changelog.
2019-09-01 23:07:12 +02:00
emacspace 592fb5863c documentation formatting: Sat Aug 31 19:04:38 UTC 2019 2019-08-31 22:15:53 +02:00
Luo Tianj b71c78655f add flycheck-clj-kondo as an optional package 2019-08-31 20:58:30 +02:00
Sam Hedin 62ea30b479 Add cider clojuredocs keybind, remove grimoire 2019-08-27 21:31:59 +02:00
John Stevenson cc43d5c898 [Clojure] keybinding spacemacs/clj-find-var
Update the existing `SPC m g g` keybinding to use the command
`spacemacs/clj-find-var`.  This makes finding a function definition a much
better experience as you dont have to have the REPL running to find a
definition, but when it is you can use a CIDER specific function.

`spacemacs/clj-find-var` is a wrapper that calls `cider-find-var` if the REPL is
running, otherwise it uses `dump-jump-go`.

Wrapper added in #9792
2019-07-13 15:12:55 +02:00
John Stevenson 8fd218f1e8 [Clojure] keybinding for updated repl jack-in commands
Latest CIDER release uses the following commands for starting the REPL from
within Emacs

`cider-jack-in-clj` to start a Clojure REPL
`cider-jack-in-clj&cljs` to start a Clojure and ClojureScript REPL
`cider-jack-in-cljs` to start a ClojureScript repl

The older aliases are deprecated and are being removed in the latest beta
release of CIDER

`cider-jack-in`
`cider-jack-in-clojurescript`

Keybindings for these jack-in commands have been updated and as there are three
options they have been moved under the repl > jack-in

The top level of the Clojure mode menu has the existing keybindings updated to
use the new commands.  A third top-level keybinding `&` has been added for
`cider-jack-in-clj&cljs`
2019-07-13 14:41:06 +02:00
duianto e12278a323 Revert "[Clojure] Keybinding require Clojure repl utils in current namespace"
This reverts commit 034ee0c311.

It was rebased with the previous commits message.
2019-07-13 14:40:44 +02:00
John Stevenson 034ee0c311 [Clojure] Keybinding require Clojure repl utils in current namespace
Although the Clojure repl utils (clojure.repl) are including in the user
namespace in Clojure projects, they are not available in your application
namespace.

The existing CIDER function cider-repl-require-repl-utils adds the Clojure
repl utils into the current namespace, so you can use functions such as doc
and source.

This is often a source of confusion for those new to Clojure / CIDER.
2019-07-13 12:50:11 +02:00
John Stevenson cd95789170 [Clojure] Keybinding require Clojure repl utils in current namespace
Although the Clojure repl utils (clojure.repl) are including in the user
namespace in Clojure projects, they are not available in your application
namespace.

The existing CIDER function cider-repl-require-repl-utils adds the Clojure
repl utils into the current namespace, so you can use functions such as doc
and source.

This is often a source of confusion for those new to Clojure / CIDER.
2019-07-13 11:52:32 +02:00
JAremko 6c12121cec fix links 2019-07-08 23:56:07 +03:00
Jonathan Chen 28adf374fe feat(clojure-lang): add `cider-eval-sexp-at-point`
Adds a useful CIDER command that doesn't have an idiomatic Spacemacs command.

Ref:
https://cider.readthedocs.io/en/latest/interactive_programming/#using-cider-mode
2019-07-06 00:17:03 +02:00
John Stevenson bb34374818 Add keybinding for cider-interupt
Interrupt longer running evaluations without having to kill or reset the REPL
connection.

Placed in the evaluate section, as it is specific to the currently running
evaluation.
2019-06-13 15:27:02 +02:00
duianto 47f83609d5 [clojure][doc] markdown inline code to org verbatim
Change surrounding characters: markdown inline code to org verbatim.
2019-06-13 01:27:48 +02:00
Liu Chong bd61f2e8a0 Remove `cider.nrepl/cider-middleware` in lein quick start setting
Don't need this `cider.nrepl/cider-middleware` in lein profiles.clj.

It will result in error, the `cider.nrepl/cider-middleware` not middleware but a vector of all cider-nrepl middlewares:

> https://github.com/clojure-emacs/cider-nrepl/blob/master/src/cider/nrepl.clj#L483
2019-06-12 19:31:16 +02:00
emacspace c7c348a676 documentation formatting: Sun May 26 20:58:52 UTC 2019 2019-05-27 01:23:35 +03:00
JAremko 5cc823cc0f add flycheck-clojure 2019-05-18 02:17:43 +03:00
Anton-Latukha f6660f82d4
Switch to the new layers generator 2019-05-15 21:08:21 +03:00
Anton-Latukha 2ee74f55da layers: lang: new structure: add DSL (&markup), framework, util
layers: lang: mv framework -> programming/framework

layers: programming: framework: upd
2019-05-15 21:05:09 +03:00
JAremko 77c680160e Add placeholder tags 2019-05-05 20:40:47 +03:00
John Stevenson 831107f478 [clojure] keybinding - cider-undef - remove symbol from current ns
Adds `SPC m e u` to the Clojure layer to call `cider-undef`, removing an
existing definition from the current namespace.

This provides a Spacemacs style keybinding for the existing Emacs style
keybinding `C-c C-u`
2019-04-20 15:26:55 +02:00
emacspace 18a998b675 documentation formatting: Thu Apr 4 16:29:54 UTC 2019 2019-04-04 23:19:59 +02:00
John Stevenson 074588475b Clojure Layer - Updated docs for Cider manual quick start
Updated documentation for Clojure layer to currently recommended versions of
build tools and `cider-nrepl`, ensuring that connecting to a manually run
Clojure REPL works correctly with the current version of CIDER.

Leiningen version 2.9.0
Boot version 2.8.2
`cider-nrepl` 0.21.1
2019-04-03 18:31:17 +02:00
emacspace 45276bd96f documentation formatting: Wed Dec 5 03:03:03 UTC 2018 2018-12-04 22:06:14 -05:00
emacspace db0dd6d945 documentation formatting: Fri Nov 16 19:57:10 UTC 2018 2018-11-16 20:21:32 +00:00
yuhan0 f13f99d967 Enable clojure-mode refactorings without clj-refactor
- Add clojure-mode refactorings and which-key prefixes in default layer
configuration.

- Improve discoverability of the refactoring features which are not enabled
by default. When clj-refactor is installed, "SPC mr?" runs
cljr-describe-refactoring

- Refactor out repeated dolist clauses into `forall-clojure-modes` macro
which executes body forms for all clojure derived modes, and adds missing
functionality of parinfer, fancify-symbols and evil-cleverparens to
cider-repl-mode and cider-clojure-interaction-mode.
2018-11-16 19:51:21 +00:00