This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2020-08-11
Channels
- # babashka (3)
- # beginners (70)
- # calva (15)
- # cider (34)
- # clara (10)
- # cljsrn (2)
- # clojure (28)
- # clojure-europe (21)
- # clojure-france (1)
- # clojure-uk (17)
- # clojuredesign-podcast (4)
- # clojurescript (51)
- # cursive (21)
- # data-science (1)
- # datalog (2)
- # datascript (2)
- # datomic (10)
- # emacs (5)
- # esprit (24)
- # expound (9)
- # figwheel-main (15)
- # fulcro (31)
- # graphql (3)
- # jobs-discuss (27)
- # keechma (2)
- # luminus (2)
- # malli (2)
- # minimallist (14)
- # nrepl (1)
- # off-topic (4)
- # pathom (1)
- # pedestal (8)
- # re-frame (10)
- # reagent (5)
- # reitit (2)
- # rewrite-clj (54)
- # sci (1)
- # shadow-cljs (34)
- # spacemacs (12)
- # sql (17)
- # vim (16)
- # web-security (1)
Our @olical is speaking at vimconf. The agenda was just released, congratulations!
i've been wanting to attend vimconf for a while now, but a ticket to japan has been a hard sell to my employer 😄
You know if you have a form akin to this (-> (foo bar) (baz qux))
and you want to delete the outer form, i.e., the (-> ...)
and (possibly) shift (foo bar) (baz qux)
to align left, is that doable? btw, the outer form could be anything, like (when (a b) (c d))
, so in this case, the (when ...)
would be removed, leaving the (a b)
(c d)
intact.
I use vim-sexp to move the close paren two forms to the left, then d%
to remove (->)
that remains
there's probably something more elegant
If you visually select the (foo bar) (baz qux)
then you can <localleader>o
and the selection will take the place of the outer form. I don't have a nifty way of selecting the two inner forms though...
try viF
v- visual iF - inner form
Thanks, that's closer. The selection also includes ->
but I'll be using viF
more often now :thumbsup:
there's also aF
to include the outer parens, and af
to select inner rather than outer form
I like to stick to the action / qualifier / thing combos because they reduce the number of things I need to memorize to do things in few keystrokes
#TIL <localleader>@
and <localleader>o
. (There are too many sexp mappings to remember 😓.) Thanks guys!
As for selecting forms, I find the WORD motions vim-sexp-mappings-for-regular-people most comfortable for that https://github.com/tpope/vim-sexp-mappings-for-regular-people#motion-mappings