Skip to content
This repository has been archived by the owner on Jun 1, 2018. It is now read-only.

cosmin/lein-iclojure

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 

Repository files navigation

lein-iclojure

IClojure plugin for Leiningen.

Installation

Leiningen 1.x

lein plugin install lein-iclojure 1.2

Leiningen 2

Add [lein-iclojure "1.2"] to the :user profile in ~/.lein/profiles.clj. Here is an example

{:user {:plugins [ [lein-iclojure "1.2" ]}}

Usage

To launch an IClojure REPL within the context of a project you'll have to use trampoline.

lein trampoline irepl

To launch a standalone IClojure REPL you can simply run

lein irepl

Trampoline and project classpath

By default the current version of Leiningen runs code that needs a project classpath in a subprocess. The problem is this blocks access to user input, and is therefore not appropriate for IClojure.

We can try to cheat by running IClojure in a separate classloader, however this won't provide the necessary classpath isolation. For example, IClojure will use the version of Clojure that ships with Leiningen (1.2.1) instead of the version required by the project.

Therefore the only available option is to use trampoline. This is a facility provided by Leiningen to get around the limitations above. When running a task within trampoline, Leiningen will execute that task after Leiningen's JVM exit.

License

Copyright (C) 2013 Cosmin Stejerean

Distributed under the Eclipse Public License, the same as Clojure.

About

Leiningen plugin to launch an IClojure REPL

Resources

Stars

Watchers

Forks

Packages

No packages published