Discussion about all editors used for Clojure/ClojureScript
jasongilman 2016-03-08T01:39:59.000083Z

I just created a gist describing my Atom setup. I thought I'd mention it here. https://gist.github.com/jasongilman/d1f70507bed021b48625#file-my_atom_clojure_setup-md

nkraft 2016-03-08T15:22:39.000084Z

Anyone using MacVim and Fireplace for Clojure? I usually use emacs for development, but I've been playing with Vim and Fireplace too. Fireplace seems to have a problem, though: I can connect to my repl without problems, and the formatting commands all work, but when I try cqc or cqp I get "not an editor command".

nkraft 2016-03-08T15:22:50.000085Z

Is this a MacVim thing, or am I doing something wrong?

snoe 2016-03-08T15:52:14.000086Z

@nkraft: cqc and cqp are normal mode mappings not commands. (So not on the : prompt).

nkraft 2016-03-08T16:02:31.000087Z

Thanks @snoe. Still getting used to Vim for Clojure. I use it a lot for bash scripts, but that's been about it.

snoe 2016-03-08T16:22:51.000088Z

np, if you look up at @dominicm message he has a pretty good run down of some of the things you can do with vim and clojure.

dominicm 2016-03-08T17:46:57.000089Z

I should push up my files and do a video

dominicm 2016-03-08T17:47:13.000090Z

I've got some really nice stuff lately.

dominicm 2016-03-08T17:47:45.000091Z

As in, since I started my job I've been forced to optimise.

dominicm 2016-03-08T17:49:29.000092Z

I want to put together a motion for doing clojure comments over a range

dominicm 2016-03-08T17:49:42.000093Z

I think that would be super cool

dominicm 2016-03-08T17:49:52.000094Z

Not a motion, a, action?

nkraft 2016-03-08T18:03:13.000095Z

@dominicm: That was a great list you put above, got me started with Vim and Clojure. Love to see more of your thoughts on the subject.

dominicm 2016-03-08T18:09:24.000096Z

@nkraft I'll try. I'm pretty new to doing advanced stuff.

nkraft 2016-03-08T18:19:00.000097Z

@dominicm: So am I, though you're ahead of me in the vim+clojure world. :simple_smile:

dominicm 2016-03-08T18:29:39.000098Z

@nkraft: Ah, so you're not new to vim, I misread I think.

nkraft 2016-03-08T18:38:06.000099Z

@dominicm: I've just used vim for quick hacks on bash and python scripts. This venture into vim+clojure is the first time I've tried to use vim for serious development. I usually turn to emacs+cider for that, but I find I'm enjoying vim a lot.

dominicm 2016-03-08T18:38:20.000100Z

I ❤️ sexp.

nkraft 2016-03-08T18:38:32.000101Z

Me too.

dominicm 2016-03-08T18:38:36.000102Z

It brings a bunch of text objects you need.

nkraft 2016-03-08T18:39:06.000103Z

Though I dislike paredit in any editor.

dominicm 2016-03-08T18:39:20.000104Z

Steve Losh used Clojure for a while, so he has some interesting configs for sexp. But he uses Paredit.vim as well, I need to check out what he uses each for.

dominicm 2016-03-08T18:40:05.000105Z

paredit.vim pretty much just provides sexp (with weird mappings imo), and paren balancing.

nkraft 2016-03-08T18:45:10.000106Z

If it's anything like paredit in Emacs, I do not want a set of commands or mappings for editing parenthesis, I want to manage them in my editor. I could rant about paredit all afternoon, but I won't. Suffice to say that I've disliked it for more than 10 years, and I don't think I'm going to "see the light" anytime soon. :simple_smile:

dominicm 2016-03-08T18:46:15.000107Z

Interesting.. 😛 I love the ability to just use a binding, and wrap an element in parens, move an element back and forth, etc.

nkraft 2016-03-08T18:51:27.000108Z

Lots of people feel like you do about paredit. I know I'm in the minority. After years of common lisp and other lispy languages, I have muscle memory and a workflow that makes paredit feel like a rude guest in my editor.

dominicm 2016-03-08T18:53:04.000109Z

I'm interested to see how you work more than anything 😛

dominicm 2016-03-08T18:53:52.000110Z

It would be really cool.

snoe 2016-03-08T18:57:31.000111Z

@nkraft well I think that same feeling was an inspiration for parinfer. I would like to hear a rant on paredit though, it's something I hear every so often but don't fully understand.

dominicm 2016-03-08T19:30:19.000112Z

@snoe what did you use pre-parinfer?

snoe 2016-03-08T19:30:41.000113Z

a mix of paredit and sexp

snoe 2016-03-08T19:31:07.000114Z

now I'm using all three :simple_smile: because nothing is great

dominicm 2016-03-08T19:31:09.000115Z

ah, why a mix? Which parts? Might I want to copy that? HMMM? 😛

snoe 2016-03-08T19:32:11.000116Z

paredit for D handling mostly. sexp for movement, transpose, wrapping. parinfer for paren ballencing etc

dominicm 2016-03-08T19:32:48.000117Z

Yeah, that's pretty much all I miss from paredit.vim, I thought so

dominicm 2016-03-08T19:33:02.000118Z

I've managed to survive without by just doing "dae" generally.

dominicm 2016-03-08T19:33:19.000119Z

parinfer handles D pretty well.`

nkraft 2016-03-08T20:01:00.000120Z

I just have time for a mini-rant, but my biggest peeve is the way Paredit tries too hard to be "helpful" and enforce a way of writing code. If I have (fnc 1 2) and I want to add (a (fnc 1 2)) I want something to tell me when I don't match the parenthesis, but I don't want to hit '(' and get '() (fnc 1 2)' with a right parenthesis that I now can't move except with paredit's special commands. Changing (fnc 1 2) to (a (fnc 1 2)) takes me four keystrokes with no visual confusion. Paredit just doesn't improve on that.

nkraft 2016-03-08T20:01:30.000121Z

I spend half the time using paredit with it disabled so it will get out of my way.

dominicm 2016-03-08T20:03:44.000122Z

I agree there, vim-sexp has some insert mode mappings, and you can turn those off (without losing everything else)

dominicm 2016-03-08T20:04:27.000123Z

although, I have become one with my editor in that case, and just do umm... ,i and it wraps turns (fnc 1 2) into ( (fnc 1 2))

nkraft 2016-03-08T20:07:17.000125Z

My brain just doesn't think like that. When I want a parenthesis, my fingers hit the parenthesis keys. It does sound, though, like using paredit in vim might be a bit less trouble than it is in Emacs.

nkraft 2016-03-08T20:09:22.000126Z

That's just me, though. Since I started coding before paredit was around, I already had a workflow and style when everyone jumped on the paredit bandwagon.

snoe 2016-03-08T20:10:43.000127Z

Well wrap exists in emacs paredit, and I think that vim's paredit stuff is much less "helpful" than emacs. It does sound like you might enjoy parinfer

nkraft 2016-03-08T20:21:49.000128Z

I'll give it a try. I just installed it in my vim. Seems a lot less heavy-handed than Emacs paredit. Llet's see how the rest of the day goes.

nkraft 2016-03-08T20:22:16.000129Z

Thanks for the parinfer pointer.

dominicm 2016-03-08T20:25:07.000130Z

vim is generally less rude

nkraft 2016-03-08T20:27:20.000131Z

I'm getting that feeling about vim.