Hi,
In my case port 8080 is in use on my laptop because another application
runs on 8080.
Wouldn't it be a good idea to make the port 8080 the default and
provide an option to start script/repl with another port.
Then:
script/repl -h
could tell about the possibility to specify your own p
Hi Randy,
On Sun, 1 Aug 2010 15:02:59 -0700 (PDT)
Randy Hudson wrote:
> I think we're almost there, sorry for the various mistakes.
>
> If you look in the source for clojure.xml, you can see that the
> default "startparse" argument for xml/parse is
>
> (defn startparse-sax [s ch]
> (.. SAXPa
Hi Randy,
On Sun, 1 Aug 2010 10:04:16 -0700 (PDT)
Randy Hudson wrote:
> Right you are Michael; sorry for the missing paren at the end of the
> def.
>
Now compiling the code works:
(def parser (.newSAXParser (SAXParserFactory/newInstance)))
(.setEntityResolver (.getXMLReader parser) resolver
Hi Randy,
On Sun, 1 Aug 2010 06:23:58 -0700 (PDT)
Randy Hudson wrote:
> Hi Manfred,
>
> I'm sorry the code wasn't quite correct. The EntityResolver is set on
> the parser's XMLReader, not on the parser itself:
>
> (def parser (.newSAXParser (SAXParserFactory/newInstance))
> (.setEntityResolver
Hi Randy,
Thanks for your help. A bit late my answer because in the meantime I was
on vacation and only now found the time to pursue it further.
On Tue, 29 Jun 2010 18:53:30 -0700 (PDT)
RandyHudson wrote:
> Yes, you can do this by defining an EntityResolver that corrects the
> bad system id, de
Hi there,
I got a directory tree of xml documents all having the same dtd.
However the dtd file is not where the DOCTYPE SYSTEM entry says it is.
Currently, xml/parse throws an exception that the dtd file will not be
found.
Is there a possibility to tell xml/parse about a different location
of th
Hi Phil,
On Wed, 16 Jun 2010 21:24:55 -0700
Phil Hagelberg wrote:
> I'm pushing for a Leiningen 1.2.0 release really soon now, and part of
> that effort is sprucing up the documentation. I've revamped the readme
> and added a tutorial for folks just getting started. Of course,
> self-editing is
On Sat, 10 Apr 2010 15:10:58 -0700
Brendan Ribera wrote:
> Try this instead:
>
...
> > > >:main *nailgun.*example)
> >
Thanks a lot.
Yes
:main nailgun.example)
does work fine.
--
Manfred
--
You received this message because you are subscribed to the Google
Groups "Clojure" gr
Hi Phil,
On Sat, 10 Apr 2010 09:54:29 -0700
Phil Hagelberg wrote:
> On Sat, Apr 10, 2010 at 3:27 AM, Manfred Lotz
> wrote:
> > <snip-->
> > (defproject example "0.1"
> > :desc
Hi there,
As a clojure newbie I tried to run a nailgun example from Phil
Hagelburg which I found here in the archive.
I created a directory example. In example I put a file project.clj
(defproject example "0.1"
:desc
Hi Per,
On Sun, 4 Apr 2010 15:28:23 +0700
Per Vognsen wrote:
> (map #(fn? (when-let [x (resolve (symbol %))] @x)) ["map", "first",
> "nofun"]) should do the trick. But before you go ahead and do this,
> make sure it's what you actually need.
>
> -Per
>
Thanks a lot. That was exactly what I w
Hi there,
I can ask if something is an fn, like this: (fn? first)
How do I do it when first is a string?
Example:
(def mylist '( "map", "first", "nofun"))
This doesn't work, of course:
(map fn? mylist)
How can I transpose, e.g. "first" to something so that I can feed fn?
with it?
--
On Sun, 7 Mar 2010 12:35:27 +0800
Mike Mazur wrote:
> Hi,
>
> On Sat, Mar 6, 2010 at 20:36, Manfred Lotz
> wrote:
> > Now I tried a different way:
> >
> > (defstruct st :a :b)
> >
> > (defn my-struct-map [s & inits]
> > (let [sm (struct-map
On Mon, 1 Mar 2010 11:01:36 -0800 (PST)
ataggart wrote:
> No, but if you need to do that, then you can do what deftype sort-of
> does:
>
> user=> (defstruct St :a :b)
> #'user/St
> user=> (defn st ([a] (struct St a 0.0)) ([a b] (struct St a b)))
> #'user/st
> user=> (st 5)
> {:a 5, :b 0.0}
>
>
Hi,
Can I have a default value for a member of a structure which is not
specified when doing a struct-map?
Minimal example: I have (defstruct st :a :b) and always when I define
something like this (struct-map st :a 4) omitting :b I would like to
have :b set automatically to 0.0 instead having nil.
On Sun, 24 Jan 2010 12:33:11 -0800 (PST)
".Bill Smith" wrote:
> Manfred,
>
> The (:require clojure.contrib.classpath) tuple tells the ns function
> to load the clojure.contrib.classpath library if it has not already
> been loaded. Clojure looks for clojure/contrib/classpath.clj (or the
> equiva
On Sun, 24 Jan 2010 12:28:16 -0800 (PST)
Justin Kramer wrote:
> You may find this ns cheatsheet helpful:
>
> http://gist.github.com/284277
>
> Justin
>
A good pointer.
--
Thanks,
Manfred
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post
Hi,
On Sun, 24 Jan 2010 17:07:23 +0100
Meikel Brandmeyer wrote:
>
> > But why does this fail?
> >
> > my=> (classpath)
> > java.lang.Exception: Unable to resolve symbol: classpath in this
> > context (NO_SOURCE_FILE:2)
>
> Because you used require. Try clojure.contrib.classpath/classpath
> i
Hi all,
I'm stumbling about the very basics.
Calling clojure like this:
rlwrap java
-cp /home/manfred/clojure/clojure.jar:/home/manfred/clojure/clojure-contrib.jar
clojure.main
I try:
user=> (ns my (:require clojure.contrib.classpath))
nil
my=>
which to me looks fine.
But why does this fai
19 matches
Mail list logo