Sonian is hiring Clojure developers

2012-10-31 Thread joegallo


http://www.sonian.com/about/careers/software-engineer-clojure-cloud/

Come work at Sonian and you'll be writing Clojure full-time, working
on interesting big data problems. The Sonian software stack comprises
multiple applications tied together with queues and rest interfaces,
focused on archiving and indexing over a petabyte of email. Everything
runs in the cloud (hundreds of nodes), and is thoroughly automated:
Want to check if your branch is good? Ask our IRC bot (written in
Clojure) to run tests on it! Tests passed? Ask the bot to merge your
branch!

Our team is fully remote, but we emphasize pairing with tmux and Skype
(and emacs!). In addition to Clojure/conj, a few times a year,
everybody gets together for a week in Boston to talk and hack
together.

If you want to know more, email me (joe.ga...@sonian.net), or if
you've already decided to apply, send your resume, cover letter,
github account, etc, to j...@sonian.net. Use subject line "Software
Engineer, Clojure / Cloud".

All the best,
Joe

(We're also hiring Ruby/Rails devs, btw!)

-- 
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 - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Sonian is hiring Clojure developers

2012-10-31 Thread joegallo


> Is US-based a requirement set in stone? 


It's more of a timezone thing than a citizenship or location thing.  We 
have employees in North and South America, but a good number of activities 
(pairing generally and standup specifically) seem to work best if people 
are working the same hours more or less.

-- 
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 - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Creating a map algorithmically

2011-08-09 Thread joegallo
(zipmap (range 2 (inc n)) (repeat true))

-- 
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 - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Doric 0.6.0

2011-11-11 Thread joegallo
I just released a new version of doric (https://github.com/joegallo/doric) 
-- it's a fun little utility library that you might want to look at if 
you're using clojure.pprint/print-table, but want a few more features than 
it provides.  This version includes support for generating csv, raw text, 
and html tables, in addition to the default emacs org-mode tables.  New 
custom table formats can also be created by supplying a namespace that 
implements 3 functions (see the source for examples).

Happy hacking!

-- 
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 - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Adding a jar to dependencies in lein

2011-11-11 Thread joegallo
Go to search.maven.org, and type in jericho-html.  That'll take you to some 
results pages that will tell you the versions that are available, and also 
the correct groupId and artifactId.

Then you add into project.clj the following [groupId/artifactId 
"version"].  In this case, [net.htmlparser.jericho/jericho-html "3.2"] 
should work.

Joe

-- 
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 - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: java logging properties and lein

2011-11-14 Thread joegallo
You could drop it into the root of src, or you can add a :resources-path 
"etc" in your project.clj and then put it in the root of that.  Some 
purists would probably argue that the latter is better, but the former 
should work just fine, too.

-- 
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 - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

A few enhancements

2011-12-01 Thread joegallo
Here are some things I've run across in Clojure that seem asymmetric to me 
-- I looked through Jira for issues related to these, but I didn't find any 
(of course, I might have just missed them).  Some of these might be valid 
enhancements that would make sense to add, some of them might be a case of 
me having a bad mental model and wanting the wrong thing from the 
language.  I'm hoping to get some feedback to help me determine which is 
which, and then I'll write some patches for the ideas that are good ones.  
I've tried to avoid making any statements about the world (e.g. x is y), 
these are all just statements about my personal experience (e.g. x seems 
like y to me).

1.
user=> (keyword 'foo) 
:foo 
user=> (keyword "foo")
:foo
user=> (keyword :foo)   
:foo  
user=> (symbol "foo")   
foo 
user=> (symbol 'foo) 
foo   
user=> (symbol :foo)  
ClassCastException clojure.lang.Keyword cannot be cast to java.lang.String  
clojure.core/symbol (core.clj:522)

I've never wanted to create a symbol from a keyword, but this seems 
asymmetrical to me.

2.
user=> (name 'user)
"user"
user=> (name :user)
"user"
user=> (name "user")
"user"
user=> (name *ns*)
ClassCastException clojure.lang.Namespace cannot be cast to 
clojure.lang.Named  clojure.core/name 
(core.clj:1488) 



I think of namespaces as being a thing that has a name, so I would expect 
to be able to call name on them.  I always do this first, and then it blows 
up, and then I remember ns-name, but that returns a symbol, not a string 
(which I also always forget), so then I finally have to pipe that through 
name or str, which ends up seeming messier than it should to me.

user=> (name (ns-name *ns*))
"user"

One solution to that would be name namespaces a clojure.lang.Named, where 
they return their own name -- which seems reasonable to me.  But that would 
lead us to this next case, below.

3.
user=> (namespace 'foo)
nil
user=> (namespace 'user/foo)
"user"
user=> (namespace :foo)
nil
user=> (namespace ::foo)
"user"
user=> (namespace *ns*)
ClassCastException clojure.lang.Namespace cannot be cast to 
clojure.lang.Named  clojure.core/namespace (core.clj:1496)

If we make Namespaces a clojure.lang.Named, then they'll also need to have 
an implementation of getNamespace.  I suppose we could return the 
namespace's name, but does that imply that a namespace is in itself?  That 
seems wrong to me.  Another option would be to return nil, which indicates 
that a namespace is not in a namespace, which is true, but possibly 
confusing.  A third possibility would be to split Named into Named (has a 
name) and Namespaced (has a namespace), and then we don't have this issue 
at all -- we'd be free to say that namespaces are Named, but not 
Namespaced. 

   


4. 
user=> (symbol "bar")
bar   
user=> (symbol 'bar)  
bar   
user=> (symbol "foo" "bar") 
foo/bar 
user=> (symbol "foo" 'bar)   
ClassCastException clojure.lang.Symbol cannot be cast to java.lang.String  
clojure.core/symbol 
(core.clj:523)  
  

user=> (symbol 'foo 'bar)  
ClassCastException clojure.lang.Symbol cannot be cast to java.lang.String  
clojure.core/symbol 
(core.clj:523)  
user=> (symbol *ns* 
'bar)   
 

ClassCastException clojure.lang.Namespace cannot be cast to 
java.lang.String  clojure.core/symbol 
(core.clj:523) 
user=> (symbol *ns* "bar")
ClassCastException clojure.lang.Namespace cannot be cast to 
java.lang.String  clojure.core/symbol 
(core.clj:523)

I always forget that symbol allows a string or a symbol for first argument, 
but that when you have two arguments, they must both be strings.  It's 
another "d'oh!" thing for me that I find myself correcting a lot.  I'd also 
like to be able to construct a symbol with a namespace object directly, not 
just the string that represents the namespace's name.

Anyway, what do you think?  If there are any smart ideas here, I'd be happy 
to create a jira ticket and attach a patch with tests.

Joe

-- 
You received this message because y

Re: Get multiple vals from a map

2011-12-01 Thread joegallo
((juxt :foo :bar) {:foo 1 :bar 2 :baz 3}) 

juxt to the rescue

-- 
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 - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: A few enhancements

2011-12-05 Thread joegallo
I've added a new ticket http://dev.clojure.org/jira/browse/CLJ-891 to jira 
for adding the ability to make (symbol some-ns "bar") work.  That tackles 
half of the issue in #4, and reduces your example to just (symbol *ns* 
(name sym)).

-- 
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 - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: inconsistency in (keyword…) constructor

2012-03-02 Thread joegallo


> PS. same issue with (symbol name) and (symbol ns name)…
>

Huh, somehow I noticed this issue with symbol, but didn't see it with 
keyword.  I guess I've need the two arg version of symbol, but never needed 
the two arg version of keyword.

See some related discussion here: 
https://groups.google.com/d/topic/clojure/n25aZ5HA7hc/discussion

-- 
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 - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Re: Bug in try/finally?

2010-08-11 Thread joegallo
On Aug 11, 9:02 am, Chouser  wrote:
> Have you sent in your CA?

It's in the capable hands of the USPS.

Joe

-- 
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 - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en


Re: Today's clojure trick question

2010-08-18 Thread joegallo
> However, if you do (let [x (java.lang.Boolean/getBoolean "false")] (if
> x :trouble :ok)) you're fine, which obviously isn't helpful in your
> situation.

Boolean.getBoolean() is pretty evil, too.  It was featured in one of
Joshua Bloch's java puzzlers (which might have been borrowed from
somewhere else, I don't know if it was originally his).  Watch out, it
might not do what you think it does. :)

For instance:
System.out.println(Boolean.getBoolean("false"));
System.out.println(Boolean.getBoolean("true"));
System.out.println(Boolean.getBoolean("fred"));

will print false three times.

Joe

-- 
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 - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en