
Nightcode: An IDE for Clojure and Java - anon1i40292
http://nightcode.info/
======
SCdF
This seems to be the blog post about it:
[http://www.marshut.com/sspkm/nightcode-an-ide-for-clojure-
an...](http://www.marshut.com/sspkm/nightcode-an-ide-for-clojure-and-
java.html)

It's nice to see people getting passionate about this sort of thing, but it's
incredibly alpha, and atm it doesn't seem to have any features worth writing
home about. At least, not from what I could tell after playing around with it
for a little bit.

~~~
gw
I'm the creator of Nightcode, and I agree, which is why I didn't announce it
here. It is pretty half-baked and I was hoping to fix some of the more obvious
bugs before promoting it more. That being said, I can't really complain.

~~~
voltagex_
Any plans for Clojurescript support?

Also, is it just me or is every new editor/IDE using that same Sublime-ish
colour scheme?

~~~
auggierose
If you are wondering about Clojurescript support, just take a look at the
screenshot ...

~~~
voltagex_
Oops, I hadn't looked - I haven't played with Clojurescript yet, but it's on
my list.

------
jnbiche
I see this (very cool-looking) IDE has one-click Clojure Android project
skeletons. I'm in the midst of Android development, and find that Java is
slowing me down more than I would have anticipated. I just can't sketch out
ideas like I do in scripting languages. So my question is: how is Clojure on
Android these days? I know that historically, it's had some performance
issues. Are these getting better? Is interaction with the Android API pretty
seamless?

I'm half-tempted to use Nightcode just to spare me the pain of trying to set
up a Android project using Clojure. If any of the previous non-Java languages
I've used on Android are any indication (Python and Lua, mainly), it's a huge
pain in the ass. I really wish Google had built a more polyglot-friendly
environment in Android.

~~~
MBlume
This seems like the place to start. [https://github.com/clojure-android/lein-
droid](https://github.com/clojure-android/lein-droid)

------
ganarajpr
This is amazing.. The greatest thing you have done ( I havent checked out the
whole IDE yet ) is to reduce the whole step of setting things up down to 1
click.. The biggest gripe I had with Clojure / Cljs was the setup process.. I
am not familiar with the java world and I hate setting things up before
getting my hands dirty. This sir, does everything for me.

Just wow! and thank you.

~~~
emn3m
If you're looking for a Clojure IDE, you should check out Light Table:
[http://www.lighttable.com/](http://www.lighttable.com/)

~~~
dktbs
Although I agree that LightTable is a more polished clojure IDE, it doesn't do
the one thing that ganarajpr mentioned: create lein projects for you through
the UI.

Even though lein is easy to use, integration like this lowers the barrier to
entry for new folks wanting to learn clojure, which is awesome.

~~~
chongli
Doesn't anyone else find it odd that command-line tools would be a barrier to
entry for _programmers_? Sure, I see it all the time; I just don't get what
people are expecting.

------
gw
I just released 0.0.2, so those who are having issues with running and
building on 0.0.1 may have better luck this time. It also now correctly uses
command instead of control for keyboard shortcuts on OS X.

As I said before, it is still a very early release, so please let me know
about other bugs you find.

------
joeblau
I'm using IntelliJ which has so far been great for great for Clojure and Java
plus every other language I use. I'm definitely willing to give this a shot
and I also want to know if you're looking at doing any Scala support?

~~~
dpratt
I'm in the same boat - I've been a very happy IDEA user for over a decade now,
and any other IDE that targets the JVM has a pretty high bar as far as I'm
concerned.

With that said, I'd _love_ to see the Scala equivalent of this - the Scala
plugin for IDEA works fairly well (they still have quite a few problems with
inline error highlights/parsing when your Scala code uses path dependent
types), but the Typesafe official Scala IDE uses Eclipse, which utterly rules
it out as far as I'm concerned.

A lightweight but functional Scala-native IDE with builtin sbt support would
be absolutely awesome for a pure-Scala project.

~~~
dyadic
I write Clojure and Scala, Clojure got me into Emacs and then Emacs+Ensime led
me away from IDEA for Scala development. I recommend it fully.

I am a big fan of IDEA and use that for Java and Groovy, and also Jetbrains'
AppCode for Obj-C development, but the Scala support in IDEA is currently just
not good enough.

~~~
joeblau
How is AppCode compared to xCode? Everyone has been telling me I need to make
the switch but I don't want to break any of my existing iOS projects.

~~~
dyadic
I can't really give you a fair comparison, I've only used Xcode enough to know
that I don't like it.

I don't even think the full switch can ever be made. Because it's Apple
development, everything is in an "Xcode project" (instead of, say, "iOS
project"). So even using AppCode I'm still dropping back to Xcode some of the
time.

------
krstck
Would this be a good resource for learning Clojure for someone who's a rather
inexperienced programmer? I remember looking at Leiningen a while back and
being a little lost. I've heard really good things about Clojure and
functional programming in general but I still have my programmer training
wheels on.

~~~
alanning
Re: learning resources, I found the book "Clojure Programming" by Chas
Emerick, Brian Carper, and Christophe Grand to be excellent.

[http://www.clojurebook.com/](http://www.clojurebook.com/)

After reading through that, the exercises at
[http://4clojure.com/](http://4clojure.com/) helped me to solidify things and
learn what the core library has available. Work through a problem on your own
and then check out how someone like 'immo' or 'jbear' did it.

------
test-it
How does it compare to Emacs, Idea and Eclipse?

I've been planning to learn a modern (compared to Interlisp, which I used in
the 80s) Lisp for a long time. What stops me is the need to 1st learn a very
complicated IDE.

I'm also having some doubts about Clojure compared to true Lisps - those store
all data as lists for a very good reason - it allows fantastic code reuse.

~~~
calibraxis
About your last point, Clojure's seqs enable code reuse. You can operate on
lists, vectors, sets, maps, etc as seqs. I don't know about Interlisp, but
Common Lisp does not unify these datatypes under such a common sequence
abstraction.

~~~
emiljbs
>I don't know about Interlisp, but Common Lisp does not unify these datatypes
under such a common sequence abstraction.

[http://www.lispworks.com/documentation/HyperSpec/Body/c_sequ...](http://www.lispworks.com/documentation/HyperSpec/Body/c_sequen.htm)

[http://www.lispworks.com/documentation/HyperSpec/Body/t_seq....](http://www.lispworks.com/documentation/HyperSpec/Body/t_seq.htm)

[http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.65....](http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.65.1604&rep=rep1&type=pdf)

[https://github.com/sbcl/sbcl/blob/master/src/pcl/sequence.li...](https://github.com/sbcl/sbcl/blob/master/src/pcl/sequence.lisp)

EDIT: Some actual problems
[http://ilc2009.scheming.org/node/7](http://ilc2009.scheming.org/node/7)

~~~
calibraxis
Yes, I had Rhodes' work in mind. In Common Lisp, sequences are hardcoded as
lists and vectors. [1] Which excludes the sets and hashtables (which I
mentioned), not to mention anything sequence-like which users might come up
with. (Actually, it doesn't even have sets built in. I've seen people use
degenerate hashtables to simulate them — keys which just hash to true.)

Furthermore, the by far most common mapping functions operate only on proper
lists, not sequences. [2] And in the very popular (albeit notorious) LOOP
macro, one must even use in/across/"k being the hash-key using (hash-value
v)", depending on whether you're operating on lists, vectors or hashtables
respectively! [3]

(Of course, one could add these things to CL, in the sense that you have all
of CL's power in C — by implementing CL atop C. Or you could invent your own
generic seq functions, and hope others use it.)

Someone could point out that had CL's standard had continued to evolve, it
might've had these things. Or that these limitations were due to weaker
computers. But whatever happened happened, and this is the real-world CL we
have. CL's a wonderfully powerful language (not counting the troll-dominated
community), but there's seams.

[1]
[http://www.lispworks.com/documentation/HyperSpec/Body/26_glo...](http://www.lispworks.com/documentation/HyperSpec/Body/26_glo_s.htm#sequence)

[2]
[http://www.lispworks.com/documentation/HyperSpec/Body/f_mapc...](http://www.lispworks.com/documentation/HyperSpec/Body/f_mapc_.htm)

[3]
[http://www.unixuser.org/~euske/doc/cl/loop.html](http://www.unixuser.org/~euske/doc/cl/loop.html)

~~~
emiljbs
" But whatever happened happened, and this is the real-world CL we have."

Some of my links were there to point out that it's not really, we do have
extensible sequences in SBCL for example.

Thanks for making such a long reply for what basically was link dumping.

------
manishsharan
I am unlikely to witch my Java IDE away from Netbeans and unfortunately
Netbeans does not have any support for Clojure. (Enclojure is dead).I wish
someone would would develop a Clojure plugin for NB. That would solve a real
problem for those gently switching to Clojure.

~~~
TylerE
IDEA shouldn't be too foreign to you, and I'm pretty sure the clojure plugin
runs in the free community edition.

------
bachback
I like the idea and might contribute to the source.

I have the feeling the response to keystrokes is somewhat delayed? Type "asdf"
for example and you will set it takes perhaps 1.5x more than it should and its
not even.

------
toisanji
there are quite a few editors to code in clojure and I don't see how you can
differentiate from the others, but good luck, it looks promising. I personally
use macvim/vim.

~~~
ldh
Are there really that many Clojure IDEs available? I suspect you're conflating
IDE and text editor.

~~~
rsynnott
I think the only major one is the IntelliJ plugin (though SLIME is a sort of
marginal case).

~~~
tobik
don't forget the Eclipse plugin Counterclockwise:
[https://code.google.com/p/counterclockwise/](https://code.google.com/p/counterclockwise/)

------
Xorlev
Hey, this is awesome. I've never been able to get too far with Clojure because
of unfamiliarity with tooling and lack of desire to setup Emacs/Slime.

~~~
crucialfelix
Emacs + nrepl if properly set up is really the killer combo. You get instant
popup-style access to documentation, auto-complete, repl and unit test
integration.

with paredit the ( ) handle themselves pretty much.

I wrote up some notes on setting it up here:

[http://crucialfelix.github.io/clojure/2013/05/16/learn-by-
wr...](http://crucialfelix.github.io/clojure/2013/05/16/learn-by-writing-in-
the-repl/)

------
guiomie
I am getting : "Error: Could not find or load main class nightcode.lein" when
clicking "Run" in ClojureScript, v 0.0.3.

------
krisc
This looks exciting. The Android integration is really attractive to me. I'll
be sure to try this out soon. Thanks, gw!

------
guiomie
I can't figure out how to use/find templates ...

