ninjudd / drip

Fast JVM launching without the hassle of persistent JVMs.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

iclojure started thought drip fails at readline

vi opened this issue · comments

In iclojure started normally on my Debian Wheezy I can use up,down,Home,End and other keys. But in iclojure started thought drip those keys produce some capitalized letters (and I have to use ^P, ^N, ^F, ^B instead to natigate around).

Also iclojure startup time is still slow even if I use drip...

Just use Leiningen. REPLy, which version 2 uses, is probably the best Clojure REPL out there and it has built-in readline support.

iclojure seems to be using a plugin and lein trampoline. This very likely means the JVM trampoline starts is not started via Drip.

I was trying stand-alone iclojure and "iclojure" script are edited to use "drip".

REPL-y is fine (I see only one omission compared to iclojure: can't tab-complete object's Java methods), but the issue still conflicts with "drop-in replacement of java"...

@vi let me explain. iclojure does not start the REPL. It starts Leiningen which, via a feature called trampoline which basically makes Leiningen set up the classpath, run another JVM with it and exit. So it is Leiningen's trampoline that is running whatever the plugin is that iclojure uses.

If tools are not aware of Drip, they will use the regular java runner. Drip developers cannot change every single tool out there.

You can prevent drip from being used at all with a leiningen invocation by setting LEIN_JAVA_CMD=.

iclojure is started directly, not using lein trampoline irepl.

By default iclojure script does this:

  1. Check if we are inside Leiningen project.
  2. If inside Leiningen project, start lein trampoline irepl
  3. If not in any Leiningen project, $JAVA -client -jar $ICLOJURE_JAR. And I had JAVA=drip before that line.

First time (without pre-loaded instance) it started normally, but the second time (using pre-loaded JVM) it behaved poorly.

You can prevent drip from ... -> The question is not about preventing or enabling drip. The question is about drip and readline. Is drip intended to be used only with Leiningen or with any Java application?

Drip is known to be used with JRuby