jcpetkovich / .emacs.d

This is my emacs config
5 stars 0 forks source link

Push multiple-cursor layer to spacemacs #1

Open kleewho opened 9 years ago

kleewho commented 9 years ago

Any chance to push it to spacemacs? I'm stealing it from you for now, but I think I'm not the only one who would like to have it upstream.

jcpetkovich commented 9 years ago

There are some pretty hefty disadvantages to it, like having to learn emacs keybindings, but sure, that's not a bad idea. On May 20, 2015 4:25 AM, "Łukasz Klich" notifications@github.com wrote:

Any chance to push it to spacemacs? I'm stealing it from you for now, but I think I'm not the only one who would like to have it upstream.

— Reply to this email directly or view it on GitHub https://github.com/jcpetkovich/.emacs.d/issues/1.

kleewho commented 9 years ago

I'm a emacs user, which switched to spacemacs couple of weeks so it's not a problem for me.

Two questions.

I'm realy not a vim/evil guy so I don't know but maybe you will whether there's something built-in that can do the same thing in vim/evil?

Did you try to add keyboard mappings with some leader-key in that layer? That would be even more awesome.

jcpetkovich commented 9 years ago

The best multi-cursor-edit like feature that's available for evil is what's already in spacemacs, see here https://github.com/syl20bnr/spacemacs/blob/master/doc/DOCUMENTATION.md#replacing-text-with-iedit

But the functionality of iedit pales in comparison to multiple-cursors. Unfortunately, evil does some pretty crazy things with commands, and that makes it very difficult to get it working correctly with multiple-cursors. The best thing I've come up with so far is this layer and the code in it, it makes it so that using multiple-cursors switches you to emacs mode and handles all the cursor fiddling necessary to make that smooth.

What do you mean add keyboard mappings with some leader key? What in particular are you interested in? Do you want the spacemacs leader key available within emacs mode? (because it's already available, M-m by default).

kleewho commented 9 years ago

I mean, it would be nice to have multiple-cursor functionality under let's say <Leader>qss like qursor-select-similar. But if there are problems with evil then I guess it doesn't matter so much, because it won't be available in normal mode.

Even after I stole that layer from you I still can't make it work. I must do it wrongly

jcpetkovich commented 9 years ago

Ah I see what you mean now. I haven't added it to the leader key no. But it would definitely have a binding in there if I submitted it.

What exactly is going wrong? What are the steps you are following to get it working?

kleewho commented 9 years ago

Probably I've been doing something wrong but I'm to tired to check it today. I'll take care of it tomorrow as I'm very interested in getting it to work.

jcpetkovich commented 9 years ago

Any luck with this?

edrex commented 8 years ago

Hi @jcpetkovich and @kleewho, there's PR https://github.com/magnars/multiple-cursors.el/pull/216 to make multiple-cursors work with evil-mode. As soon as that's merged, maybe we can update this layer and get it into spacemacs.

jcpetkovich commented 8 years ago

That's definitely the plan. I'm very interested to see how well the PR works. I've yet to have the time to try it. On Oct 19, 2015 12:05 PM, "Eric Drechsel" notifications@github.com wrote:

Hi @jcpetkovich https://github.com/jcpetkovich and @kleewho https://github.com/kleewho, there's PR magnars/multiple-cursors.el#216 https://github.com/magnars/multiple-cursors.el/pull/216 to make multiple-cursors work with evil-mode. As soon as that's merged, maybe we can update this layer and get it into spacemacs.

— Reply to this email directly or view it on GitHub https://github.com/jcpetkovich/.emacs.d/issues/1#issuecomment-149259930.

edrex commented 8 years ago

now it's looking like spacemacs might use a new package, evil-mc. It's present in the develop branch.