This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-11-19
Channels
- # announcements (3)
- # asami (3)
- # babashka (39)
- # beginners (65)
- # calva (13)
- # cider (4)
- # clj-kondo (69)
- # cljdoc (19)
- # cljs-dev (2)
- # clojure (90)
- # clojure-dev (10)
- # clojure-europe (61)
- # clojure-france (15)
- # clojure-nl (8)
- # clojure-uk (2)
- # clojurescript (28)
- # conjure (2)
- # core-logic (4)
- # cursive (8)
- # datalevin (5)
- # datascript (7)
- # datomic (14)
- # depstar (4)
- # events (1)
- # graphql (7)
- # holy-lambda (5)
- # jobs (5)
- # kaocha (1)
- # malli (14)
- # membrane-term (13)
- # missionary (13)
- # nextjournal (6)
- # off-topic (1)
- # polylith (15)
- # portal (10)
- # re-frame (35)
- # reitit (1)
- # remote-jobs (3)
- # schema (3)
- # sci (121)
- # spacemacs (6)
- # tools-build (8)
- # tools-deps (74)
- # xtdb (7)
I've been searching for a way to replace the REPL console window with the Portal plugin. I've been playing with repl commands for a few days and have recently come up with :
(ns ~file-namespace)
(try (tap> (eval '~top-level-form))
(catch Throwable t
(tap> t)))
I like it because taps forms that cannot be evaluated.
Anybody else have Cursive repl commands that might be worth sharing?Hi @cfleming, is there any plan to support paredit-convolute-sexp
? I sometimes miss this functionality.
https://github.com/cursive-ide/cursive/issues/809
Sorry, I missed this when you posted it. I could do, but I never found a decent explanation online of how it should work.
I think emacs’s document explains the behavior. > “Convolute S-expressions. > Save the S-expressions preceding point and delete them. > Splice the S-expressions following point. > Wrap the enclosing list in a new list prefixed by the saved text. > With a prefix argument N, move up N lists before wrapping.” https://github.com/emacsmirror/paredit/blob/8330a41e8188fe18d3fa805bb9aa529f015318e8/paredit.el#L2181 Calva’s implementation https://github.com/BetterThanTomorrow/calva/blob/986b4fd1afd84a916c6c460acb7a9a69f08e4692/src/cursor-doc/paredit.ts#L879
An example used in Calva https://calva.io/paredit/
(let [s [1 2 3 4 5]]
(->> s
(map (apply + [1 2 3]))
|(repeat 4)
(zipmap (range 4))))
;Save the S-expressions preceding point and delete them.
;Saved S-expressions are
;->> s
; (map (apply + [1 2 3]))
(let [s [1 2 3 4 5]]
(|(repeat 4)
(zipmap (range 4))))
;Splice the S-expressions following point.
(let [s [1 2 3 4 5]]
|(repeat 4)
(zipmap (range 4)))
;Wrap the enclosing list in a new list prefixed by the saved text.
(->> s
(map (apply + [1 2 3]))
(let [s [1 2 3 4 5]]
|(repeat 4)
(zipmap (range 4))))
@U40AQPFAM Thanks, I’ve updated the Github issue with those examples. It’s probably likely to be a low priority with everything else I have to do, though.