Skip to content

p-b-west/enclojure

 
 

Repository files navigation

Enclojure

This project is a fork of Eric Thorsen's original Enclojure project. I have got it building and working on NetBeans 7.3.

Builds are available on timboudreau.com.

Big Honkin' Caveats

Update 8/14:

The caveats below still apply, plus:

  • Project depends on https://github.com/technomancy/swank-clojure for its REPL, which is unmaintained; its website recommends using CIDER instead
  • The embedded version of Clojure is 1.2.0, while Clojure is up to 1.6.0; it uses clojure-contrib which has not existed since 1.2.0, and has since been split apart into multiple libraries - someone needs to determine which are actually needed and include only those.
  • The project is not compilable against versions of Clojure newer than 1.2.0

The module will work with NetBeans 8.0 + Clojure 1.2.0 (a copy of Clojure is included in the module), but you must disable the Hibernate NetBeans plugin first.

Older Caveats:

This module cannot coexist with NetBeans Hibernate support, due to a conflict over SLF4J. So, disable hibernate before you try to use this module. This is probably solvable, but would probably require changes in NetBeans Hibernate module to split out SLF4J into a wrapper both could depend on.

There are other issues - the naive approach to integrating a scripting language into an IDE is to load up user code inside the IDE's VM. In practice this has disasterous consequences - user code gets to wreak havoc with the IDE. This plugin does exactly that, so caveat emptor.

The SLF4J problem in more detail:

  • Clojure really, really wants to use the system classloader (you can assign it, but there is no obvious entry point)
  • The Clojure Maven Plugin does not run in Maven's compile scope, so SLF4J cannot be a compile-scope dependency - so it ends up on the module classpath
  • The Hibernate plugin also includes a copy of SLF4J
  • The classloader Clojure ends up using has two copies of SLF4J on it, and for very sane reasons refuses to arbitrarily choose one or the other

There is some code that assumes other Clojure code that initializes the REPL window will have run before a project or the editor is opened; in practice windows are lazy-loaded, so having it open is a good idea.

About

A Clojure plugin for NetBeans, revived

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Java 79.8%
  • Clojure 20.2%