Clojure-Specific Emacs Environment

462 views
Skip to first unread message

ian.tegebo

unread,
Mar 29, 2012, 3:48:02 AM3/29/12
to clo...@googlegroups.com
tl;dr 

Is anyone working on a Clojure-Specific Emacs Environment?  If considered but dismissed, then why?

----

I've just reviewed a thread about nREPL.  The thread also (somewhat indirectly) calls into question the current practice of piggy-backing on SLIME:

"About a networked REPL..."

I also see a GSoC project,
(I realize that this project's existence is probably my answer, but I thought I'd check anyway.)

And lastly, this design page,

There also seems to be no shortage of (revised/deprecated) howto's and confusion regarding Emacs and SLIME.  I can't help but think that this is at least in part due to SLIME's release process and the various ways that Clojure is not Common Lisp.  There also appears to have been some back and forth on the slime-devel list that may exemplify this.

In any case, the fact remains that I still can't get the workaround to work as smoothly as I'd like (for both an old and new installation of SLIME):

(I can switch once between CL and Clojure, but then I get errors.)

While it may make sense to just fix the issues with maintaining multiple versions of SLIME, all the facts seem to point towards a Clojure-Specific Emacs Environment.  

That said, there's certainly been a lot of work that's gone into swank-clojure, clojure-mode, and clojure-test-mode so I can understand the queasiness involved with a rewrite.  Also, I imagine that the CL part of the community is quite small.  However, I'd also like to use swank-js with a newer SLIME than currently works with clojure-mode as it appears to be the best REPL integration for Javascript.  I imagine that the Javascript part of the Clojure community is quite a bit larger (although the Emacs+desire+for+REPL constraint certainly restricts that amount).

Finally, we get to the point.  Tool development is essential. And right now my tools are becoming clojure-mode and things like kibit, slamhound, swank-js, SLIME, and redshank.  I've tried to understand SLIME's implementation a few times already.  At this point, I need to be able to improve Clojure related tools a lot more than CL ones.  If I can defer understanding SLIME, the more the better.  Lastly, I expect a rewrite could stay relatively clean given that quite a bit of work can be pushed into nREPL related tooling...where we can write in Clojure!

Phil Hagelberg

unread,
Mar 29, 2012, 12:52:58 PM3/29/12
to clo...@googlegroups.com
On Thu, Mar 29, 2012 at 12:48 AM, ian.tegebo <ian.t...@gmail.com> wrote:
> Is anyone working on a Clojure-Specific Emacs Environment?  If considered
> but dismissed, then why?

The problem is that swank-clojure+slime offers a local maximum. While
there are difficulties working with CL and Clojure at the same time,
it seems that most people lose interest in CL after using Clojure for
a while. Maybe swank-js changes the equation a bit.

While there would be benefits to implementing an elisp frontend to
nrepl, it would be a lot of work before it would catch up with what
we've already got. The swank-clojure codebase is ancient, and since
its original author abandoned it, there's no one who really
understands it and is willing to hack on it apart from simple
maintenance tasks.

Anyway, I'd be happy if someone went ahead with nrepl.el even so;
don't let me discourage you.

Nearly all the code in clojure-mode is orthogonal to swank/slime; it's
focused around static font-lock and indentation rather than
interacting with a live process. There's slime-specific stuff in
clojure-test-mode, but it would be pretty trivial to make it work with
another interface.

-Phil

> --
> You received this message because you are subscribed to the Google
> Groups "Clojure" group.
> To post to this group, send email to clo...@googlegroups.com
> Note that posts from new members are moderated - please be patient with your
> first post.
> To unsubscribe from this group, send email to
> clojure+u...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/clojure?hl=en

Phil Hagelberg

unread,
Apr 23, 2012, 7:08:37 PM4/23/12
to clo...@googlegroups.com
On Thu, Mar 29, 2012 at 9:52 AM, Phil Hagelberg <ph...@hagelb.org> wrote:
> Anyway, I'd be happy if someone went ahead with nrepl.el even so;
> don't let me discourage you.

For what it's worth I sketched out a bare skeleton of what this could
look like. Nothing works yet, but if someone were to want to hack on
it, this might be a good place to start:

https://github.com/technomancy/nrepl.el

I don't have plans to finish it myself.

-Phil

Tim King

unread,
Apr 26, 2012, 10:27:26 AM4/26/12
to clo...@googlegroups.com
I have been working on a fork of Phil's nrepl.el for the past few nights.
So far I have gotten the basic bencode/bdecode transport working and am able to send and receive to an nREPL server.
Beyond that, it isn't really in anything close to a usable state yet, but I plan to continue plugging away at it.


Cheers,
Tim "not an emacs lisp hacker" King

Phil Hagelberg

unread,
Apr 26, 2012, 2:10:07 PM4/26/12
to clo...@googlegroups.com
Tim King <kin...@gmail.com> writes:

> I have been working on a fork of Phil's nrepl.el for the past few
> nights.
> So far I have gotten the basic bencode/bdecode transport working and
> am able to send and receive to an nREPL server.
> Beyond that, it isn't really in anything close to a usable state yet,
> but I plan to continue plugging away at it.

Wonderful! Best of luck to you. Let us know once you've got something
that needs testing.

-Phil

Sam Aaron

unread,
Apr 27, 2012, 3:40:42 AM4/27/12
to clo...@googlegroups.com
Fantastic work Tim. I think this can be a really important part of the future for Clojure hacking with Emacs. Let us know how you get on.

Sam

--
http://sam.aaron.name


On Thursday, 26 April 2012 at 15:27, Tim King wrote:

> I have been working on a fork of Phil's nrepl.el for the past few nights.
> So far I have gotten the basic bencode/bdecode transport working and am able to send and receive to an nREPL server.
> Beyond that, it isn't really in anything close to a usable state yet, but I plan to continue plugging away at it.
>
> http://www.github.com/kingtim/nrepl.el
>
> Cheers,
> Tim "not an emacs lisp hacker" King
>
> On Mon, Apr 23, 2012 at 4:08 PM, Phil Hagelberg <ph...@hagelb.org (mailto:ph...@hagelb.org)> wrote:
> > On Thu, Mar 29, 2012 at 9:52 AM, Phil Hagelberg <ph...@hagelb.org (mailto:ph...@hagelb.org)> wrote:
> > > Anyway, I'd be happy if someone went ahead with nrepl.el even so;
> > > don't let me discourage you.
> >
> >
> > For what it's worth I sketched out a bare skeleton of what this could
> > look like. Nothing works yet, but if someone were to want to hack on
> > it, this might be a good place to start:
> >
> > https://github.com/technomancy/nrepl.el
> >
> > I don't have plans to finish it myself.
> >
> > -Phil
> >
> > --
> > You received this message because you are subscribed to the Google
> > Groups "Clojure" group.
> > To post to this group, send email to clo...@googlegroups.com (mailto:clo...@googlegroups.com)
> > Note that posts from new members are moderated - please be patient with your first post.
> > To unsubscribe from this group, send email to
> > clojure+u...@googlegroups.com (mailto:clojure%2Bunsu...@googlegroups.com)
> > For more options, visit this group at
> > http://groups.google.com/group/clojure?hl=en
>
> --
> You received this message because you are subscribed to the Google
> Groups "Clojure" group.
> To post to this group, send email to clo...@googlegroups.com (mailto:clo...@googlegroups.com)
> Note that posts from new members are moderated - please be patient with your first post.
> To unsubscribe from this group, send email to
> clojure+u...@googlegroups.com (mailto:clojure+u...@googlegroups.com)

Tim King

unread,
Apr 27, 2012, 9:37:43 AM4/27/12
to clo...@googlegroups.com
Thank you Sam and Phil for the encouragement.  And thanks Phil for getting it rolling with the initial version.

I'll update the group as soon as I feel I have something ready to test.

Cheers,
Tim
Reply all
Reply to author
Forward
0 new messages