Just started teaching myself Clojure, there's one thing that seems to elude
me. I'd like to be able to pretty print output from my project in the
REPL. Clearly it already supports coloring text somehow, but I can't
figure out how to do it myself and haven't been able to figure out the
trick.
Can you be more specific about how you are loading the namespace?
I can't reproduce this with a pure Clojure repl or with a Leiningen repl on
Clojure 1.7 or 1.8.
On Sunday, September 13, 2015 at 6:23:37 PM UTC-5, Gregg Reynolds wrote:
>
> PS.
>
> REPL-y 0.3.5, nREPL 0.2.10
> Clojure 1.7.0
> J
Something like this can work but you need to have the proper path in the
local maven_repository. You have the repository named local. Inside the
repo, every artifact has a groupID (the first part of the dependency), the
artifactID, and the version. If you had a dependency like:
[SSAM "0.1.0"]
I am lazy so I was hoping to find a simple way to do this. My co-worker has
written a complex app in Java which does natural language processing. He
delivered it to me as an uberjar. My app is suppose to call his app as a
library.
The path to the file is:
/Users/rollio/projects/rollio/nlp-ho
> Memoize takes the ignored argument into account
> when associating the inputs with outputs.
This is the answer I was looking for. I feel like this is the subtlety that
I had missed.
On Saturday, September 12, 2015 at 5:24:55 AM UTC-4, Moe Aboulkheir wrote:
>
>
>
> On Sat, Sep 12, 2015 at
PS.
REPL-y 0.3.5, nREPL 0.2.10
Clojure 1.7.0
Java HotSpot(TM) 64-Bit Server VM 1.8.0_45-b14
On Sun, Sep 13, 2015 at 6:21 PM, Gregg Reynolds wrote:
> Just to be perverse, in my library I'm defining `print`. So I get the
> usual warning:
>
> WARNING: print already refers to: #'clojure.core/prin
Just to be perverse, in my library I'm defining `print`. So I get the
usual warning:
WARNING: print already refers to: #'clojure.core/print in namespace:
migae.datastore, being replaced by: #'migae.datastore/print
So I add a clause to my (ns...) form:
(:refer-clojure :exclude [print])
This h
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Hi,
> I'm about to start a new web project and they are thinking about
> using Go (golang) instead of a JVM (preferably Clojure) based
> approach. The idea is "BARE METAL SPEED!!!", but I really think
> the network and DB will be the bottlenecks, not
On Sun, 2015-09-13 at 12:44 -0700, Alan Thompson wrote:
> Hi,
>
> I'm about to start a new web project and they are thinking about
> using Go (golang) instead of a JVM (preferably Clojure) based
> approach. The idea is "BARE METAL SPEED!!!", but I really think the
> network and DB will be the
There's the TechEmpower benchmarks at:
https://www.techempower.com/benchmarks
Interestingly, Clojure is currently ahead of Go in the single and multiple
database query benchmarks.
- James
On 13 September 2015 at 21:44, Alan Thompson wrote:
> Hi,
>
> I'm about to start a new web project and the
Hi,
I'd love to see some discussion about this as well: I've struggled to justify
the JVM in a production environment that's dominated by Go. My experience with
my team has been that they are very unwilling to use the JVM and will go to
great lengths to avoid it. The argument seems to be that G
P.S. I have seen the results at
https://github.com/ptaoussanis/clojure-web-server-benchmarks although I'm
not sure exactly how to interpret them w.r.t. "keepalive" and the "errors"
graph. Also, the plotted results don't seem to include latency.
Alan
On Sun, Sep 13, 2015 at 12:45 PM, Alan Thomps
Hi,
I'm about to start a new web project and they are thinking about using Go
(golang) instead of a JVM (preferably Clojure) based approach. The idea is
"BARE METAL SPEED!!!", but I really think the network and DB will be the
bottlenecks, not Clojure vs Go.
Is anybody out there aware of any spee
Rich may change the formatting at some point but I do not expect he would
accept a patch like this. Sorry.
Alex
--
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 that posts from new me
Hi,
I am working on a replication system which also works in the browser
(1). So far I have come a long way with core.async and a pub-sub
architecture, but I have avoided error-handling in the beginning, just
using a cascading close on the pub-sub architecture on errors (e.g.
disconnects). Lately
You’re right, I missed a step :-). Something like (typed in-line so it really
won’t compile):
:locations [{“us” 100} {“de” 101}]
:locations-seq (into {} (map (fn [{:keys [location]}] [:location (get locations
location)])…)
;; the above produces a sequence symmetrical with entities, each map cont
On Sunday, September 13, 2015 at 12:10:00 PM UTC-4, Artur Malabarba wrote:
>
> > This scheme won't play nicely with forms with variable numbers of
> special
> > arguments.
>
> True, but I've never seen anyone indent specially these optional
> arguments. For instance, every defn I see (including
> This scheme won't play nicely with forms with variable numbers of special
> arguments.
True, but I've never seen anyone indent specially these optional
arguments. For instance, every defn I see (including clojure.core), is
indented like this:
(defn foo
[x]
(+ x 3))
(defn bar
"Adds four t
Not sure I follow Colin's suggestion entirely, but his suggestion led me to
this which is better. I'd still love any other suggestions to improve!
(def entities [{:name "foo" :location "us"} {:name "bar" :location "de"}])
(def locations [{:location "us" :id 100} {:location "de" :id 101}])
;; mak
This scheme won't play nicely with forms with *variable numbers of special
arguments*. Of which one is one of the most common macros to use:
(defn foo
[x]
(+ x 3))
(defn bar
"Adds four to x."
[x]
(+ x 4))
--
You received this message because you are subscribed to the Goog
I also love this idea - the more info we give to tools to provide a uniform
formatting, the less I have to worry about configuring my local editor to
match the project styles.
On Sun, Sep 13, 2015 at 3:15 AM, Colin Yates wrote:
> My knee-jerk reaction is:
> - +10
> - leaving it up to the user
2015-09-13 11:15 GMT+01:00 Colin Yates :
> - the name ‘indent’ and what it is actually capturing are at different
> levels of abstraction. Possibly ‘structure’ might be a better name as that
> is what it is describing?
Good point, we should consider this. Though :structure might be a
little too a
I would transform the locations into {location id} and then use merge.
> On 13 Sep 2015, at 3:14 PM, Brian Platz wrote:
>
> I have a pattern that comes up frequently, when I need to merge some value
> into one map list from matching keys in a second map list.
>
> I've developed a way to handle
I have a pattern that comes up frequently, when I need to merge some value
into one map list from matching keys in a second map list.
I've developed a way to handle it, but I think it could be better. Here is
a simple example of it:
In the below case, we are looking to replace the :location in
Hi there,
I've been working on some patches to Compiler.java in my spare time to add
profiling and to try to add some optimisations to the code. My ultimate goal is
to identify where time is spent during our app's start-up time, so that we can
improve it.
One thing that hinders my progress i
Hi,
Please vote if that interest you:
https://github.com/krisajenkins/yesql/issues/106
Regards,
Geraldo
--
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 that posts from new members
On 13 Sep 2015 1:25 pm, "Artur Malabarba"
> Or do you mean it should be ::indent?
Typo. Ignore the "Or".
--
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 that posts from new members are
On 13 Sep 2015 12:33 pm, "Matching Socks" wrote:
>
> Unless clojure.core itself will carry these annotations, could the
keyword be namespaced?
Or do you mean it should be ::indent? (i.e., carry the namespace of the var
that they're applied on)
In this case, I think it would only make things more
Unless clojure.core itself will carry these annotations, could the keyword
be namespaced?
--
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 that posts from new members are moderated -
It's probably obvious, but let me say it just in case it isn't - I'm super
supportive of Artur's idea. I've been thinking about something similar for
a while and I believe deciding on something that's going to be used by many
Clojure tools (CIDER, Cursive, fireplace, ccw, cljfmt, etc) will be hugel
My knee-jerk reaction is:
- +10
- leaving it up to the user is absolutely the right thing to do
- the name ‘indent’ and what it is actually capturing are at different levels
of abstraction. Possibly ‘structure’ might be a better name as that is what it
is describing?
But don’t listen to a wor
Hi everyone,
Over at CIDER we're adding a feature where the author of a macro (or
function) can specify how that macro should be indented by adding an :indent
metadata to its definition. This way the editor (and other tools, like
cljfmt) will know what's the proper way of indenting any macro
Because the form appears in a syntax-quote, the # is required to,ask
syntax-quote to create an identifier rather than resolve it to the current
namespace.
On Sunday, 13 September 2015, Akhil Wali wrote:
> What does _# mean opposed to simply _? With respect to memoization of
> genus it's the same
33 matches
Mail list logo