Fork me on GitHub
#cursive
<
2015-12-09
>
cfleming00:12:21

@rantingbob: Feel free to rant here initially, and if there isn’t already a feature request then either you or I can add an issue.

rantingbob00:12:56

So...I have one thing that keeps making me want to go back to Sublime (I'm a newbie).

rantingbob00:12:19

I'd ilke ther eto be a shortcut to switch to the repl, and a shortcut to switch between panels when you have two files open at once

rantingbob00:12:29

Now...heres the thing...I don't know if that's an IntelliJ limitation

rantingbob00:12:47

or...have the REPL always have a single shortcut in the switcher

rantingbob00:12:44

I know it probably seems daft

jaen00:12:32

Well, there's a ctrl+tab switcher, but I've found it fairly annoying.

rantingbob00:12:30

Same...the repl tends to move, it won't swap files in two panels properly, and tends to open files I've recently closed if I just hit it without paying attention. In Sublime I'd just Cmd-1, Cmd-2 etc. or CMD-Arrow or what have you to quick switch

rantingbob00:12:34

As I say though...it's IntelliJ functionality, so I don't know that it's really Cursives job to fix it.

jaen00:12:31

Like I said, I agree - it's not the most ergonomic thing ever and a shortcut for switching between a buffer and REPL could certainly be useful.

cfleming00:12:50

@rantingbob: When you’re talking about panels, you’re talking about tabs in the REPL toolwindow?

rantingbob00:12:10

sorry, panels wasn't the right word, buffers would have been a better choice

cfleming00:12:10

Or tabs in the editor?

rantingbob00:12:14

tabs in the editor

rantingbob00:12:27

a button to quick swap from the repl to the editor and vice versa

cfleming00:12:42

So ESC will always get you from the REPL back to the editor.

cfleming00:12:07

If you have a number assigned to the REPL toolwindow, Cmd-<number> will jump to the REPL, but that bit is not ideal.

rantingbob00:12:08

and ideally better switching behaviour between editor buffers, so if you have two side by side you can swap between them using them more reliably

rantingbob00:12:22

That would be fine...but the number in the switcher seems to change

cfleming00:12:47

No, I’m talking about the numbers assigned to the toolwindows. This is for jumping to the REPL.

cfleming00:12:59

There are two issues here - getting to the REPL and back, and getting between editors.

rantingbob00:12:01

Ohhh...see, this is where my noob is showing

cfleming00:12:12

Let’s do the REPL first.

cfleming00:12:29

So, ESC always brings you back to the editor from the REPL.

rantingbob00:12:47

and cmd-num will get you to the repl

rantingbob00:12:55

Is there a default for num?

cfleming00:12:18

If you go to View->Toolwindows, you’ll see the numbers assigned to the toolwindows. If there isn’t one assigned to the REPL toolwindow, you can assign it one in Settings->Keymap.

cfleming00:12:07

This command is not ideal, because it behaves slightly differently depending on whether the REPL toolwindow is currently open or not.

cfleming00:12:43

I’m planning to add a new command which will, from an editor, open the REPL toolwindow, jump to it and focus the REPL editor.

cfleming00:12:08

One thing several people have requested is to be able to jump to the REPL output pane to cut and paste from there without the mouse.

rantingbob00:12:11

That sounds perfect, but thank you in the meantime

cfleming00:12:31

So this new command would jump to the REPL if you’re in an editor, and then toggle from the REPL editor to the REPL output.

jaen00:12:45

@cfleming: oh, you can pin letters in ctrl+tab? Good to know.

cfleming00:12:47

And ESC would always take you back to the editor.

cfleming00:12:57

Now: editor tabs.

cfleming00:12:33

See Window->Editor Tabs for the various commands that are available there.

cfleming00:12:10

Just get rid of the tabs altogether, your life will be better simple_smile

rantingbob00:12:18

So the thing that I actually want you're already working on, and the rest I just didn't know cos noob 😉 Thank you for your patience

cfleming00:12:19

Cmd-E shows recent files

rantingbob00:12:38

I know this is probably not the done thing...but

rantingbob00:12:55

When you eventually ship Cursive as it's own thing...if you think that's what the UI should be...you should ship it like that

rantingbob00:12:03

I think anyway

cfleming00:12:23

Well, it’s controversial - for total newbies, the toolwindows etc can actually help to find things.

cfleming00:12:00

Plus I can’t reconfigure people’s UI for them in IntelliJ. When I make a standalone IDE, I’ll have more control there, and I can ask the user at first launch what they want.

cfleming00:12:13

Which will also fix the nightmare that is keybindings.

rantingbob00:12:25

For the record, I do mean when ou ship the standalone IDE

cfleming00:12:35

BTW I also have some sublime-like keybindings submitted by a user if you’re interested.

cfleming00:12:53

Just got them the other day, I haven’t had time to publish them yet.

rantingbob00:12:59

TBH, I'm pretty comfortable with your keybindings

rantingbob00:12:22

its mostly just switching betwen buffers (I like to have tests and code open side-by-side)

rantingbob00:12:29

and I want to be able to quick switch to the repl

rantingbob00:12:32

that's about it

rantingbob00:12:45

I don't know enough Clojure to really stress anything else in the system simple_smile

cfleming00:12:00

Ok. Try those options, and let me know if you’re still having problems.

rantingbob00:12:17

Cool. Thank you.

rantingbob00:12:42

Oh, I also watched your video on using grammars to improve Clojure errors. It was very interesting.

cfleming00:12:06

With a bit of luck some or all of that might make it into Clojure proper.

rantingbob00:12:32

Is it in discussion? Or are you hinting that you're already implementing it 😉

cfleming00:12:36

Well, there’s interest but I haven’t had time to work up anything more than a basic demo, so don’t hold your breath.

cfleming00:12:59

And it’s actually quite hard, and might not even be feasible - lots more investigation required.

rantingbob00:12:18

I can't even begin to imagine

jaen00:12:20

@cfleming: so if I understood right if I set key for Other -> REPL in Settings->Keymap it should be reflected in the ctrl+tab switcher?

rantingbob01:12:11

I am...thank you

cfleming01:12:01

@jaen: I’m not sure about the ctrl-tab switcher, but if you set it to, say, CMD-9, then you can just use that key to jump right to the REPL.

jaen10:12:18

Right, it doesn't seem to.

jaen10:12:06

@cfleming: I've just started getting stack overflow when trying to open one file in my project. Does this stacktrace tell you anything? - https://gist.github.com/jaen/0b732825ae6f4262b870

jaen10:12:18

I can't open it in Cursive due to that

jaen10:12:14

I think this might have been caused by having a (defrecrod Repository ...) and referring a protocol of the same name from another namespace.

jaen10:12:26

This probably caused it to loop while trying to resolve the symbol

hlship17:12:08

Has anyone been seeing an oddness in IntelliJ where modal dialogs don't respond to mouse clicks? This started fairly recently. I've tried disabling virtually every plugin and it still seems to be happening. I don't see anything in the idea.log. Kind of at a loss.

hlship17:12:01

Fortunately, key presses still work, so IntelliJ is trying to make me break my mouse addiction.

danielcompton19:12:31

Is there a way to search all of my dependencies code?

danielcompton19:12:43

Ah yes, search with custom scope Project And Libraries

cfleming20:12:13

@jaen: Could be - if you file an issue I’ll take a look.

cfleming20:12:57

@hlship: I haven’t seen that, no. You’re on v15 now, right?

jaen20:12:19

@cfleming: sure, if I can reproduce that with a minimal test case later I'll file an issue. That would probably be more convenient for you than getting the whole project as-is.

cfleming20:12:53

@jaen: Sure, but if the project is publicly visible that’s fine too, as long as I know which file to open.

jaen20:12:32

I could make it publicly visible I guess, they ain't gonna fail me for that, I think. Give me a second.

jaen20:12:55

if it's changed to a namespaced form repository/Repository everything's in order. When I remove the namespace part - stack overflow.

cfleming20:12:29

@jaen: Ok, thanks, I’ll try to take a look today.

jaen20:12:37

@cfleming: I don't remember if asked about that before or not, but is not being able to debug protocol method bodies a fundamental limitation or something that can be fixed?

cfleming20:12:06

Oh - actually, I think you may have asked that and I ignored you - sorry

cfleming20:12:46

The issue is that it’s difficult-to-impossible for Cursive to determine for a particular piece of code, which class it’s associated with.

cfleming20:12:04

JDI assumes that you’ll be able to know this and uses the class in a lot of its APIs.

cfleming20:12:49

Currently the only thing I can do is use the namespace, and say “the class is one of my.funky.ns.*"

cfleming20:12:35

The issue there is that classes defined using reify et al don’t match that pattern. I suspect it’s probably fixable, but I haven’t looked into it yet.

cfleming20:12:44

An issue would be welcome for that too.

jaen20:12:03

I assume defrecord with protocols falls under et all then, yes? Sure, I'll file an issue when I have time. It's not a super urgent thing after all, was just curious what was the underlying cause of it not working.

cfleming20:12:25

Yeah, it’s because of the way that the classes are generated.

cfleming20:12:29

my.funky.ns/my-fn generates a class my.funky.ns$my-fn IIRC, whereas my.funky.ns.MyRecord generates a class with exactly that name.

cfleming20:12:00

I think the debugger searches for my.funky.ns$*, which doesn’t catch records etc

cfleming20:12:29

If I drop the $, my.funky.ns* would catch my.funky.ns_we_dont_want

jaen20:12:26

Yeah, I can see the problem

hlship20:12:22

@cfleming: still on 14.1, maybe time to upgrade

jaen20:12:18

@cfleming: since I'm not sure if you use but, and the repo doesn't include the generated project.clj I've put it in a gist for your ceonvenience - https://gist.github.com/jaen/a5ea75889d9cd362a00a

cfleming20:12:23

@jaen: Oh right it’s a boot project, right?

cfleming23:12:39

@jaen: https://github.com/cursiveclojure/cursive/issues/1190, I’ve cloned that repo if you want to make it private again.

jaen23:12:56

@cfleming: thanks! Let me know if you need anything more.