Re: asm-based clojure yet?

2013-06-03 Thread Aaron
I'll throw in my own work in progress as a low-footprint target of Clojure: https://github.com/aaronc/c-in-clj. It's not an attempt to compile Clojure code to C, but rather a way to write C code efficiently from Clojure that can be dynamically invoked from Clojure. On Friday, May 17, 2013 7:49:

Re: asm-based clojure yet?

2013-06-03 Thread Aaron
If you use ngen, it won't be so bad: http://clojureclr.blogspot.com/2011/12/using-ngen-to-improve-clojureclr.html On Friday, May 24, 2013 6:29:24 AM UTC-4, atkaaz wrote: > > making a note that (on my system, win7 64bit btw) clojureclr startup time > is about (at least)10 seconds. > tested both C

Re: Leiningen on CLR

2013-06-03 Thread Aaron
Just to chime in - my nleiningen prototype has a repl and a compile task, but is basically just a prototype or proof of concept. It more or less works (i.e. can download dependencies & compile namespaces), but it's very rough at this point... Hopefully soon we can put some more work into it. On

Re: leiningen checkout dependencies

2013-06-03 Thread vrakade
On Tuesday, February 5, 2013 1:35:50 PM UTC-6, Phil Hagelberg wrote: > > > This is the correct way to do it, but you need to run `lein install` in > the sub project first. > It appears it's possible to update source changes to sub-projects loaded via checkouts/ by restarting the JVM,[1] howev

Re: Clojure for Map Reduce (on hadoop > 0.22)

2013-06-03 Thread ronen
Iv used Alex version and works great (on that note thank you Alex for keeping it going) Ronen On Wednesday, May 29, 2013 11:45:13 AM UTC+3, Alex Ott wrote: > > Hi > > https://github.com/alexott/clojure-hadoop - updated version > > > On Wed, May 29, 2013 at 1:55 AM, Ramesh > > wrote: > >> Hi All

Re: ref-history-count always return 0?

2013-06-03 Thread Colin Fleming
That looks great, Tom, thanks - I'll definitely spend some time exploring that. Cheers, Colin On 3 June 2013 19:55, Tom Van Cutsem wrote: > If you're the kind of person who rather reads source code than > documentation, you might also be interested in my meta-circular > implementation of Cloju

Re: WSS Clojure client

2013-06-03 Thread Dima Sabanin
New nginx does websocket proxying, so you could terminate SSL there and use Aleph for a plain HTTP websocket server in Clojure. That's what we're doing at beanstalkapp.com. On Mon, Jun 3, 2013 at 5:47 PM, Matty Williams wrote: > I'm trying to write a clojure library that will need to connect t

WSS Clojure client

2013-06-03 Thread Matty Williams
I'm trying to write a clojure library that will need to connect to a secure websocket. I've looked at aleph which looks great but I'd need to use something like stud to handle the ssl, which as I'm writing a library isn't a great solution. I've tried looking at some java libraries but most seem

Re: No-source-path ? how to run init-db?

2013-06-03 Thread jayvandal
On Monday, June 3, 2013 12:20:34 AM UTC-6, jayvandal wrote: > > I am trying to run the my-website. > My structure is > my-website top level > src >my-website >model >

Re: alter a map in a vector (reference)

2013-06-03 Thread Alex Baranosky
You *can* update this inside the vector, but if you want to key by :id, I would personally recommend, you put the email data into a map and look it up by :id, like this: {1 {:id 1 :email {"a...@mail.com 1}} 2 {:id 2 :email {"d...@mail.com 1}} 3 {:id 3 :email {"g...@mail.com 2}}} Best, Alex O

Re: Problem seting up ritz nrepl in emacs

2013-06-03 Thread Novi Border
Hi, I have tried this already but it does not seem to work for me.. I have a working setup with normal nrepl without ritz and it is working nice for me so far. I would really like to use ritz though, for setting breakpoints and than evaluating expressions inside a let statement. Currently if I

Re: alter a map in a vector (reference)

2013-06-03 Thread Yinka Erinle
Thanks Meikel for the prompt reply, that does it. Please can you elaborate on how I can use the solution below to update a particular entry in the vector. [{:id 1 :email {"a...@mail.com 1}} {:id 2 :email {"d...@mail.com 1}} {:id 3 :email {"g...@mail.com 2}}] So I will like to write a functi

Re: alter a map in a vector (reference)

2013-06-03 Thread Meikel Brandmeyer (kotarak)
Hi, Am Montag, 3. Juni 2013 22:16:54 UTC+2 schrieb Yinka Erinle: > > Given I have the following > (def result (ref [ { :id 1 :emails { "yi...@mail.com " 1}} ] > ) ) > > I like to alter the result in a transaction to become > [{:id 1 :emails { "yi...@mail.com " 2}}]; increment the > counter

Re: optional first map argument

2013-06-03 Thread Meikel Brandmeyer (kotarak)
Hi, there is always the possibility of a macro. (defmacro defwidget [name & body] (let [[docstring [attrs _ contents] body] (if (string? (first body)) [(first body) (second body) (nthnext body 2)] [nil (first body) (next body)])] `(d

alter a map in a vector (reference)

2013-06-03 Thread Yinka Erinle
Hi, I struggling to find a way to alter a value in a map that resides in a vector. Given I have the following (def result (ref [ { :id 1 :emails { "yi...@mail.com" 1}} ] ) ) I like to alter the result in a transaction to become [{:id 1 :emails { "yi...@mail.com" 2}}]; increment the counter

Re: optional first map argument

2013-06-03 Thread Alice
> (defn my-widget >     ([attrs contents] (apply widget-creator attrs contents)) ;;I have no idea > what widget-creator might be >     ([contents] (my-widget {} contents)) >     ([] (my-widget {} [])) contents of one arity version can be a map. so the code should be (defn my-widget ([attrs c

Re: optional first map argument

2013-06-03 Thread Jim - FooBar();
On 03/06/13 19:04, Alice wrote: It's more readable. (my-widget {:id "id1"} "hello" "world") you can get to almost exactly that with the last variant I posted. (defn my-widget ([attrs contents] (apply widget-creator attrs contents)) ;;I have no idea what widget-creator might be ([conten

Re: optional first map argument

2013-06-03 Thread Alice
The same reason that hiccup tag vector is taking optional attribute map. It's more readable. (my-widget {:id "id1"} "hello" "world") vs. (my-widget {:attr {:id "id1"} :contents '("hello" "world")}) On Jun 4, 2:38 am, "Jim - FooBar();" wrote: > On 03/06/13 18:22, Alice wrote: > > > I often need

Re: optional first map argument

2013-06-03 Thread Alice
I sometimes need to inspect or modify the map in the function, but defelem only merges the map. On Jun 4, 2:30 am, gaz jones wrote: > You could look at the impl: > > https://github.com/weavejester/hiccup/blob/master/src/hiccup/def.clj > > > > > > > > On Mon, Jun 3, 2013 at 12:22 PM, Alice wrote:

Re: optional first map argument

2013-06-03 Thread Jim - FooBar();
On 03/06/13 18:22, Alice wrote: I often need to do this when writing hiccup helper functions: (defn my-widget [& args] (let [attrs(if (map? (first args)) (first args) {}) contents (if (map? (first args)) (next args) args)] ... I found this post, but considering that it

Re: optional first map argument

2013-06-03 Thread gaz jones
You could look at the impl: https://github.com/weavejester/hiccup/blob/master/src/hiccup/def.clj On Mon, Jun 3, 2013 at 12:22 PM, Alice wrote: > I often need to do this when writing hiccup helper functions: > > (defn my-widget > [& args] > (let [attrs(if (map? (first args)) (first args

optional first map argument

2013-06-03 Thread Alice
I often need to do this when writing hiccup helper functions: (defn my-widget [& args] (let [attrs(if (map? (first args)) (first args) {}) contents (if (map? (first args)) (next args) args)] ... I found this post, but considering that it is 4 years old, is there any new libra

Re: Problem seting up ritz nrepl in emacs

2013-06-03 Thread Neale Swinnerton
On Mon, Jun 3, 2013 at 4:20 PM, Novi Border wrote: > > java.io.FileNotFoundException: Could not locate complete/core__init.class > or complete/core.clj on classpath: > There's some history around this missing dependency that I don't recall the details of but,you can try adding: [clojure-com

Re: Problem seting up ritz nrepl in emacs

2013-06-03 Thread László Török
AFAIK emacs-live does not support ritz, as per this thread https://groups.google.com/forum/?fromgroups#!topic/emacs-live/TKkRXHD6XGY 2013/6/3 Josh Kamau > Did you try emacs live ? https://github.com/overtone/emacs-live > > It will give you a head start. > > Josh > > > On Mon, Jun 3, 2013 at 7:

Re: Problem seting up ritz nrepl in emacs

2013-06-03 Thread Josh Kamau
Did you try emacs live ? https://github.com/overtone/emacs-live It will give you a head start. Josh On Mon, Jun 3, 2013 at 7:22 PM, Novi Border wrote: > Hi > > It does not seem to help.. > > After removing ac-nrepl, nrepl-ritz-jack-in just hangs until I switch > buffer to *inferior-lisp*, aft

Re: Problem seting up ritz nrepl in emacs

2013-06-03 Thread Novi Border
Hi It does not seem to help.. After removing ac-nrepl, nrepl-ritz-jack-in just hangs until I switch buffer to *inferior-lisp*, after which *inferior-lisp* buffer gets the repl output but things are messed up. I can type in the repl just fine but many repl functions dont' work. For example nre

Re: Problem seting up ritz nrepl in emacs

2013-06-03 Thread László Török
Hi, I think ac-nrepl doesn't play nice with ritz, try disabling it. Las Sent from my phone On Jun 3, 2013 5:28 PM, "Novi Border" wrote: > Hi > > I am currently developing clojure in sublime text, and have tried eclipse > before, but I would like to switch to emacs for all the goodies it brings

Problem seting up ritz nrepl in emacs

2013-06-03 Thread Novi Border
Hi I am currently developing clojure in sublime text, and have tried eclipse before, but I would like to switch to emacs for all the goodies it brings. I have followed a number of tutorials for seting up emacs enviroment but I can't get the ritz debuger to work. I allways get the following err

Re: Looking for Clojure freelancers

2013-06-03 Thread Peter Taoussanis
Hi Laszlo, Actually good point - I should clarify: all the work would be completely remote. I'll normally work through some combination of GitHub, Basecamp + Trello. Payment would be through PayPal. -- -- You received this message because you are subscribed to the Google Groups "Clojure" gr

Re: Looking for Clojure freelancers

2013-06-03 Thread László Török
Damn Gmail, sorry this was not meant for the list. 2013/6/3 László Török > Hi Peter, > > I might be interested. I am a PhD candidate in Munich, where are you based? > > Regards, > > Laszlo Török > > > 2013/6/3 Peter Taoussanis > >> Hi all, >> >> From time to time I have need for one or two ext

Re: Looking for Clojure freelancers

2013-06-03 Thread Peter Taoussanis
Just occurs to me: it'd probably also be useful if you post some of your details here in case anyone else is also looking for devs. -- -- 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 Note

Re: Looking for Clojure freelancers

2013-06-03 Thread László Török
Hi Peter, I might be interested. I am a PhD candidate in Munich, where are you based? Regards, Laszlo Török 2013/6/3 Peter Taoussanis > Hi all, > > From time to time I have need for one or two extra hands (or, would that > be pairs of hands?) on larger projects. Specifically, am looking for

Looking for Clojure freelancers

2013-06-03 Thread Peter Taoussanis
Hi all, >From time to time I have need for one or two extra hands (or, would that be pairs of hands?) on larger projects. Specifically, am looking for Clojure developers that'd be interested in occasional adhoc/freelance development work. Most of my work is on the web application side, but it

Re: "I don't feel the absence of a debugger, because I've learnt enough that I don't ever need a debugger."

2013-06-03 Thread Phillip Lord
That looks really very nice. The reader macros are particularly nice because it saves messing around with the structure of your code. Phil dgrnbrg writes: > I'd like to point out a similar library I wrote for Clojure called > spyscope: https://github.com/dgrnbrg/spyscope > > With spyscope, yo

[ANN] Library updates (Redis & DynamoDB clients, logging+profiling, i18n+L10n, serialization, A/B testing)

2013-06-03 Thread Peter Taoussanis
Hi folks, just a quick update on some libraries - figure I'll do this and future updates in batches to keep from spamming the group. Hoping the formatting comes through here... *Carmine* - Redis client & message queue (GitHub ) Current version: *1.9.1* Cl

Re: ref-history-count always return 0?

2013-06-03 Thread Tom Van Cutsem
If you're the kind of person who rather reads source code than documentation, you might also be interested in my meta-circular implementation of Clojure's STM (it implements refs in terms of atoms): < https://github.com/tvcutsem/stm-in-clojure> (the vanilla MVCC version is < 200 LoC) Cheers, Tom

Re: No-source-path ??

2013-06-03 Thread Kelker Ryan
Try this. cd my-website lein repl (load-file "src/my-website/models/db.clj") 03.06.2013, 15:20, "jayvandal" : > I am trying to run the my-website.My structure is >                      my-website top level >                              src >                                my-website >