Re: Got a Clojure library?

2009-04-08 Thread Remco van 't Veer
Name: clj-android URL: http://github.com/remvee/clj-android/ Author: Remco van 't Veer Categories: android framework License: MIT Dependencies: clojure Description: Basic application framework for building Android applications using Clojure. --~--~-~--~~~---~--~~

ANN: clj-android

2009-04-08 Thread Remco van 't Veer
It's still very basic but in light of current interest in running Clojure on Android, I've released my work on setting up a framework for Android application development into the wild. The code is available at: http://github.com/remvee/clj-android/ Beware: it's experimental and incomplete!

Re: Olabani says google testing Clojure for appengine

2009-04-08 Thread Korny Sietsma
Phillip Calçado (another Thoughtworker) has also done some playing with this: http://fragmental.tw/2009/04/08/clojure-on-google-app-engine/ - Korny On Wed, Apr 8, 2009 at 3:10 PM, BerlinBrown berlin.br...@gmail.com wrote: http://olabini.com/blog/tag/gae/ -- Kornelis Sietsma korny at my

Re: Clojure on Google AppEngine

2009-04-08 Thread Paul Stadig
Nice writeup John! Thanks very much. Not sure if I made it into the first 10k developers, but I can't wait to play with this. Paul On Wed, Apr 8, 2009 at 12:52 AM, David Nolen dnolen.li...@gmail.com wrote: Very exciting, thanks for the excellent and informative writeup. On Wed, Apr 8,

Re: Porting Minilight to Clojure

2009-04-08 Thread Mark Reid
Hi Laurent, Thanks for the feedback regarding namespaces. That's exactly the sort of thing I wasn't sure I was doing correctly. I currently don't use an IDE that automatically compiles files so wasn't aware of that problem. I prefer the solution that defines a main method. My only question now

Re: Porting Minilight to Clojure

2009-04-08 Thread Laurent PETIT
Hello, function -main is a regular function, so the following works : $ echo (ns test (:gen-class)) (defn -main [] (println 1)) test.clj $ java -cp clojure.jar clojure.main -i test.clj -e (test/-main) 1 HTH, -- Laurent 2009/4/8 Mark Reid mark.r...@gmail.com Hi Laurent, Thanks for the

Scan function

2009-04-08 Thread jim
I implemented a scan function, that is a function like reduce but that returns a list of the intermediate results not just the last one. (defn scan ([f coll] (scan f (first coll) (rest coll))) ([f val coll] (when (not (empty? coll))

Re: Scan function

2009-04-08 Thread Laurent PETIT
Hi, I think this is similar to clojure.contrib.seq-utils/reductions ? 2009/4/8 jim jim.d...@gmail.com I implemented a scan function, that is a function like reduce but that returns a list of the intermediate results not just the last one. (defn scan ([f coll] (scan f

Re: Got a Clojure library?

2009-04-08 Thread Rich Hickey
Added - thanks! Rich On Apr 8, 2009, at 3:43 AM, Remco van 't Veer wrote: Name: clj-android URL: http://github.com/remvee/clj-android/ Author: Remco van 't Veer Categories: android framework License: MIT Dependencies: clojure Description: Basic application framework for building

Re: Will Clojure work on AppEngine?

2009-04-08 Thread Bruce Wang
On Wed, Apr 8, 2009 at 12:53 PM, Robin B robi...@gmail.com wrote: Tonight Google officially announced JVM support for AppEngine: http://ru.ly/Z2 JRuby on Rails is working and Clojure/Compojure works too: http://ru.ly/74 Unfortunately threading is restricted on GAE/J. Robin just found on

Re: A large Clojure deployment

2009-04-08 Thread Baishampayan Ghose
It's deployed on an Ubuntu server on Amazon EC2.  Just one server for now, but designed to scale to more.  No RDBMS! Awesome, Congratulations. I was hoping to be the 2nd famous Clojure app, but it looks you beat me to it. :-) Excuse my ignorance, but which one is the first famous Clojure

Re: New release of the enclojure plugin is up.

2009-04-08 Thread Daniel Jomphe
CuppoJava wrote: I'm just wondering if anyone who's tried this and the IntelliJ plugin can comment on how they compare. I'm wondering if Enclojure has some basic s-exp functions, like Surround-With-(). For different reasons, I've been constantly switching between NetBeans, IntelliJ and

Re: New release of the enclojure plugin is up.

2009-04-08 Thread Luke VanderHart
Excellent... this is the first release of a Clojure IDE that hasn't immediately proven itself unusable as I put it through its paces. I expect this will become my main platform for Clojure development. Thanks! -Luke On Apr 6, 8:43 pm, Eric Thorsen ethor...@enclojure.org wrote: There is a new

reading properties file: does this helper already exist?

2009-04-08 Thread Stuart Halloway
Does something like this (or better) already exist in Clojure? If not I will add it to java-utils. Thanks, Stu (defn read-properties [f] (into {} (let [props (Properties.)] (.load props (FileInputStream. f)) props)))

Re: A large Clojure deployment

2009-04-08 Thread Abhishek Reddy
On 4/8/09, Baishampayan Ghose b.gh...@ocricket.com wrote: Excuse my ignorance, but which one is the first famous Clojure app? That could be a reference to Luc Prefontaine's veterinarian hospital application. It got some press at InfoQ: http://www.infoq.com/news/2009/01/clojure_production --

Re: clojure.main always exits with code 0

2009-04-08 Thread Tom Faulhaber
I'd like to second this request. It's pretty necessary to have an exit code for any type of scripting. Of course, you can always use (System/exit result-code), but a return value is prettier to me. On Apr 5, 5:15 pm, John D. Hume duelin.mark...@gmail.com wrote: Earlier today I was surprised to

Re: reading properties file: does this helper already exist?

2009-04-08 Thread Krešimir Šojat
Can't you just write: (.load (Properties.) (FileInputStream. f)) and skip separate function altogehter? Err.. that should be: (doto (Properties.) (.load (FileInputStream. f))) .. point remains. -- Krešimir Šojat --~--~-~--~~~---~--~~ You received this message

Re: A large Clojure deployment

2009-04-08 Thread Luc Prefontaine
Yep, looks like we where the first of hopefully many production implementations... It's quite funny, we are expanding the bus logic presently and without Clojure, I wonder how much effort and Java code it would have required us. We store rules in a database (hey Stuart, we really need one !:))),

Re: Enlive questions

2009-04-08 Thread Tom Hickey
Hi Christophe, I keep running into the same problem with elements getting replaced. I'm trying to set the content of an element with raw html (from a snippet) and unable to avoid both 1) the html getting escaped and 2) the element getting replaced. I can avoid one or the other, via escaped or

Re: reading properties file: does this helper already exist?

2009-04-08 Thread Stuart Halloway
I don't like that if you treat properties as a seq you get Java Hashtable$Entry objects, instead of a vector as you would with a map, hence my into {}. But maybe it is a silly quibble since destructuring works fine with either. Stuart Can't you just write: (.load (Properties.)

Building modularised contrib with ant+ivy

2009-04-08 Thread Meikel Brandmeyer
Dear Clojurians, the recent discussions about dependency handling and a personal need led me to look at Ivy. I'm a bit annoyed to have to include a 2.5MB contrib.jar when I just want to use defvar. So I started playing with Ivy. I modified the build system of contrib to create one jar per

Re: A large Clojure deployment

2009-04-08 Thread dysinger
We have several TB of indexes w/ literally billions of documents and will be using clojure w/ hadoop soon. I appreciate the hadoop mapr job examples in clojure. This is great stuff. On Apr 7, 6:24 am, Stuart Sierra the.stuart.sie...@gmail.com wrote: Hi Sean, It's deployed on an Ubuntu

Re: Building modularised contrib with ant+ivy

2009-04-08 Thread Meikel Brandmeyer
Hi again, Am 08.04.2009 um 23:43 schrieb Meikel Brandmeyer: So I started playing with Ivy. I modified the build system of contrib to create one jar per module. The modules are organised as configurations. And by the way: you can depend on the source configuration to get the clojure source

Re: reading properties file: does this helper already exist?

2009-04-08 Thread Perry Trolard
Hi Stuart, Not sure if you saw my post at http://bit.ly/sRnfG (links to list), or the props.clj file in the Google Group. In short, it's got a Properties reader writer function. It tries to make Properties look like more native Clojure maps (i.e.keywords for keys), it also uses duck-streams

Re: New release of the enclojure plugin is up.

2009-04-08 Thread CuppoJava
Thanks for that very informative comparison. I'll give it a try immediately. -Patrick --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Clojure group. To post to this group, send email to clojure@googlegroups.com To

Java 6 dependency in clojure-contrib ok?

2009-04-08 Thread Stuart Halloway
Perry's proposed props functions (http://groups.google.com/group/clojure/browse_thread/thread/c8ec751b8e66b019/d56ed1200aa95bca ) uses some Java 6 methods. Is it ok for me to add such things to contrib, or are we maintaining Java 5 compatibility? Stu

Re: Java 6 dependency in clojure-contrib ok?

2009-04-08 Thread Howard Lewis Ship
Looks like we need a macro: (for-jvm 1.5 () 1.6 ()) What's the emoticon for 1/2 sarcastic, 1/2 happy? On Wed, Apr 8, 2009 at 4:52 PM, Stuart Halloway stuart.hallo...@gmail.com wrote: Perry's proposed props functions

Re: DISCUSS: clojure.contrib.java-utils/the-str

2009-04-08 Thread Stuart Halloway
Changed to as-str (r654). Stu In Compojure, I called this str*, but I think I like as-str a little better. - James On Apr 5, 5:19 pm, Stuart Halloway stuart.hallo...@gmail.com wrote: Never worry about the distinction between symbols, keywords, and strings when working with Java APIs

Re: Java 6 dependency in clojure-contrib ok?

2009-04-08 Thread Victor Rodriguez
On Wed, Apr 8, 2009 at 7:52 PM, Stuart Halloway stuart.hallo...@gmail.com wrote: Perry's proposed props functions (http://groups.google.com/group/clojure/browse_thread/thread/c8ec751b8e66b019/d56ed1200aa95bca ) uses some Java 6 methods. Is it ok for me to add such things to contrib, or are

Re: Enlive questions

2009-04-08 Thread Christophe Grand
Hi Tom, I'm sorry for this misfeature and, rejoice, it's gone from the ongoing redesign, there's now an explicit 'content function. The tildes are gone too! Christophe Tom Hickey a écrit : Hi Christophe, I keep running into the same problem with elements getting replaced. I'm trying to

Re: Java 6 dependency in clojure-contrib ok?

2009-04-08 Thread Rich Hickey
On Apr 8, 7:52 pm, Stuart Halloway stuart.hallo...@gmail.com wrote: Perry's proposed props functions (http://groups.google.com/group/clojure/browse_thread/thread/c8ec751b8... ) uses some Java 6 methods. Is it ok for me to add such things to contrib, or are we maintaining Java 5

clojure dependency management and build

2009-04-08 Thread Bradford Cross
When you are building something real with Clojure and Emacs/Slime/Swank - things can get a bit hairy with dependency management. I have scoured the inter-tubes in the past couple days to see what I could find. I found Lancet, for builds: http://github.com/stuarthalloway/lancet/tree/master I

clojure.contrib.lazy-xml/parse-trim forces parsing whole input

2009-04-08 Thread Jouni K . Seppänen
A friend of mine had a problem parsing a large XML file using lazy-xml/ parse-trim, because it caused all of the input to be parsed at once: http://paste.lisp.org/display/78235 It seems to me that the problem is fixed by applying a small patch (uploaded as lazy-xml.patch), wrapping the calls to

Re: clojure dependency management and build

2009-04-08 Thread Stuart Halloway
Lancet is more at proof-of-concept stage than ready for heavy lifting -- I am using a mix of Ant and Rake on my own Clojure stuff. :-) I am happy to contribute to solving some of these issues but don't have time to lead the effort. Stuart When you are building something real with Clojure

How to flatten a coll only 1 level deep?

2009-04-08 Thread Paul Drummond
I am looking for something similar to flatten (in contrib.seq-utils) but the function will only flatten one level deep: [ 1 2 3 [4 5 [6 7] ] ] --- [ 1 2 3 4 5 [6 7] ] I have tried combining functions in the seq library and I've studied the code for flatten and tree-seq to look for hints but so

Re: How to flatten a coll only 1 level deep?

2009-04-08 Thread Chouser
On Wed, Apr 8, 2009 at 10:10 PM, Paul Drummond paul.drumm...@iode.co.uk wrote: I am looking for something similar to flatten (in contrib.seq-utils) but the function will only flatten one level deep: [ 1 2 3 [4 5 [6 7] ] ] --- [ 1 2 3 4 5 [6 7] ] I have tried combining functions in the seq

Re: clojure dependency management and build

2009-04-08 Thread Phil Hagelberg
Stuart Halloway stuart.hallo...@gmail.com writes: Lancet is more at proof-of-concept stage than ready for heavy lifting -- I am using a mix of Ant and Rake on my own Clojure stuff. :-) I am happy to contribute to solving some of these issues but don't have time to lead the effort. I'm

Re: DISCUSS: clojure.contrib.java-utils/as-str

2009-04-08 Thread Stephen C. Gilardi
On Apr 8, 2009, at 8:13 PM, Stuart Halloway wrote: Changed to as-str (r654). Very nice! Should we extend as-str to any number of arguments like its close cousin str? Here's a proposed implementation: (defn as-str With no args, returns the empty string. With one arg, returns its

Re: clojure.contrib.lazy-xml/parse-trim forces parsing whole input

2009-04-08 Thread Chouser
On Wed, Apr 8, 2009 at 4:07 PM, Jouni K. Seppänen j...@iki.fi wrote: A friend of mine had a problem parsing a large XML file using lazy-xml/ parse-trim, because it caused all of the input to be parsed at once: http://paste.lisp.org/display/78235 It seems to me that the problem is fixed by