Fork me on GitHub
#cursive
<
2018-02-09
>
sparkofreason00:02:34

Apart from the one problem project, parinfer is really working great now. I really liked the smart mode when using atom, excited that we have it in cursive now.

sparkofreason00:02:17

Is there any way to to select a namespace-qualified symbol/keyword with a single command? I can select all of my-ns/foo with two "expand selections".

cfleming00:02:48

@dave.dixon Great! I’ll try to repro with that project when I get a chance.

cfleming00:02:13

No, I don’t think so at the moment - it requires two expansions I think

swlkr00:02:14

Just wanted to hop in here and say parinfer smart mode works great, I’ve found zero downsides, all upside, @cfleming delivered

cfleming00:02:47

@swlkr Great news! @shaunlebron deserves most of the credit 🙂

swlkr00:02:00

Team work

sparkofreason00:02:17

It would be cool to just select (or expand) based on Clojure syntax, a single key-combo that operated at the level of clojure literals, symbols, and collections. I was able to do part of this for collections, and it's really useful, especially in conjunction with parinfer.

sparkofreason00:02:06

With the custom macros I have for collections, it's very quick and easy to do things like cut an entire list and paste it in place of another one. I find myself wanting to do the same with other clojure syntactic elements, e.g. cut the current ns-qualified keyword, and paste it over another.

cfleming00:02:40

The problem is that it’s also often useful to e.g. just change the name part of a qualified keyword.

sparkofreason01:02:12

It's just a different use-case. I agree that you still want to do that. I can almost do what I want with macros using "Move Backward" and "Expand Selection". Works on strings and qualified keywords. For whatever reason, though, "Expand Selection" at the start of a ns-qualified symbol only selects the namespace.

cfleming01:02:13

So something that people have asked for from time to time is a way to select just sexps. Perhaps that could be generalised somewhat to “Clojure forms”, and could have a slightly different keybinding (e.g. alt-shift-up on OSX, expand selection is currently alt-up)

sparkofreason05:02:11

If you had a way to select based on the same logic used for Move Backward/Forward, then I think I could make a macro similar to what I have for s-expressions to work on symbols and literals.

sparkofreason01:02:55

That would be cool.

sparkofreason01:02:48

You can select s-expressions via keyboard macros.

cfleming01:02:06

How do you do that?

cfleming01:02:23

Something like move out backwards followed by expand selection?

shaunlebron02:02:04

@taylor and I are having problems running the new parinfer on cljs files in cursive

taylor02:02:14

CLJC too it seems

taylor02:02:24

CLJ seems fine

cfleming02:02:33

@dave.dixon’s repo is all CLJC and CLJS.

shaunlebron02:02:09

steps to reproduce: 1. new project > clojure 2. parinfer should work in core.clj 3. create new cljs namespace 4. paste in https://github.com/oakmac/atom-parinfer/blob/master/src-cljs/atom_parinfer/core.cljs 5. parinfer seems to not work in the cljs file

taylor02:02:19

it’s really nice when it works though 🙂

cfleming02:02:37

Yeah, it’s not working at all in CLJS or CLJC

cfleming02:02:51

Ok, well at least that should be easy to fix 🙂

shaunlebron02:02:56

haha, awesome

cfleming02:02:14

Ugh, yeah, IntelliJ has this really confusing thing around file types, I’m using the wrong test.

cfleming02:02:23

I’ll fix that and push a new version.

taylor02:02:50

excellent work, really enjoy using Cursive & Parinfer 👏

taylor02:02:08

I will say when I was first learning Clojure, Parinfer felt like add’l “cognitive load” so I turned it off, but now I hate not having it on!

cfleming02:02:08

Smart mode is much more intuitive I think, I’m hopeful that it shouldn’t add any cognitive load now!

taylor03:02:46

one of my only peeves with prev iteration was that pasted code was often wrongly-indented, seems totally fixed now

cfleming03:02:23

I’ve pushed 1.7.0-snapshot2 fixing that bug /cc @shaunlebron

taylor03:02:46

it’s working for me

sparkofreason04:02:22

Me too. Thanks for the fast turnaround!

gklijs06:02:49

Will try it out soon, kinda had the same like taylor I guess, but now I’m copy/pasting quit some time, which could be faster and less error-prone.

vgamula11:02:08

@cfleming, Hi! Tried new Parinfer in Cursive, looks really great! Is there an option to turn forceRebalance on (like in http://shaunlebron.github.io/parinfer/demo)? Because now I can press enter before closing brackets and they will be moved to the next line. And then I can delete closing brackets using delete button, after that parinfer stops auto-balancing. Also, when closing brackets are in the new line I can't move my cursor to the left using shift-tab.

Joe R. Smith14:02:14

I see “built from 1.7.0-snapshot” in the version notes, but I don’t seem to have any parinfer v3 features (e.g., changing subsequent line indent when I change the length of a preceding form).

firstclassfunc17:02:18

can someone tell me what version of JDK 1.8 people are using that works with Cursive

manutter5117:02:18

I seem to be using 1.8.0_144-b01. No problems using it with Cursive.

manutter5117:02:45

Officially 1.8.0_144 that is