Re: [ANN] mixfix syntax for clojure 0.2.0

2015-09-24 Thread Vitaliy Vlasov
Thank you for an awesome library! Just a couple of days ago i've posted a 
question (https://groups.google.com/forum/#!topic/clojure/AVqx5Tbn8K8) and 
it was recommended to me. A miraculous coincidence:)

Vitaliy.

On Monday, September 14, 2015 at 8:40:55 PM UTC+3, Vitaliy Akimov wrote:
>
> The main change in the release is cljs support and also ns is changed to 
> more appropriate.
>
> And here is a reminder about what the library does. It simply adds mixfix 
> operators into the language without preprocessing and changing language 
> itself. So using the library you can write clojure expressions like this:
>
>
> (defn myfun [x y] 
>(if x < 2 then x + y - 1 else (x + y) * 2))
>
>
> And also develop richer syntax EDSLs like this:
>
>
> (exec (select * from table1, table2 where col1 < col2 group by col1, col2
> ))
>  
>
> The syntax is defined using following simple directives (which are in fact 
> just macro invocations):
>
>
> (m/op 400 + [[] + [+]])
> (m/op 400 - [[] - [+]])
> (m/op 500 * [[] * [+]])
> (m/op 500 / [[] / [+]])
> (m/op 400 < [[] < []])
>
> (m/op 100 if [if [+] then []])
> (m/op 110 if [if [+] then [] else []])
>
>
>
>
> It specifies precedence, symbol to be used as a head of application in 
> result, and a pattern to be used for parsing.
>
> For more details check project's github home: 
> https://github.com/awto/mixfix-clj
>
> Regards, Vitaliy
>
>

-- 
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
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [ANN] Leiningen 2.5.3

2015-09-24 Thread James Elliott
Awesome! I got the Homebrew recipe updated to include this (there were some 
additional changes needed to accommodate their new sandbox mechanism on 
their Continuous Integration server), so now everyone using Homebrew is 
past the GPG issue, and I can be back on their mainline release.

On Monday, September 21, 2015 at 5:04:12 PM UTC-5, Jean Niklas L'orange 
wrote:
>
> Greetings, Clojurians.
>
> I am happy to announce the release of Leiningen version 2.5.3. This version
> contains mostly bugfixes, most notably an issue where environment 
> variables were
> not propagated down to GPG. This caused `lein deploy` and similar commands 
> to
> fail if you set up GPG with the `GPG_AGENT_INFO` environment variable. In
> addition, `lein vcs tag` now supports `--no-sign` if you do not want to 
> sign
> your git tags.
>
> Here's a list of user-visible changes:
>
> ## 2.5.3 / 2015-09-21
>
> * Add CHANGELOG.md to default lein templates. (Daniel Compton)
> * `lein vcs tag` now supports the `--no-sign` flag. (Daniel Compton)
> * Fix a bug where javac errors were not printed to terminal. (Brandon 
> Shimanek)
> * Fix a bug where environment variables were not propagated down to GPG. 
> (Brandon Shimanek)
> * `lein retest` now saves information on which tests that fail. (Shalaka 
> Patil)
>
> For those who manually installed, `lein upgrade` will pull in 2.5.3, and 
> `lein
> downgrade 2.5.2` will bring you back to the previous version if you run 
> into any
> issues.
>
> Thanks to all the contributors who made this happen!
>
> -- Jean Niklas
>
>

-- 
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
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Immediate streaming of shell cmd stdout to a browser

2015-09-24 Thread Karel Miarka
Hi,

I want to run a long running bash script from a webapp and see it's 
continuous results on the page. I use conch to get the process' output 
stream and use this simple ring handler:

(defn handler [req]
  (response/response
(let [p (sh/proc "/home/xyz/build.sh")]
  (ring-io/piped-input-stream
#(io/copy (:out p) % :buffer-size 1)))
...

And run-jetty with :output-buffer-size 1 option, but the output is 
unfortunately displayed at once after the process finishes.

Any idea?

Thanks,
Karel

-- 
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
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


defprotocol/deftype namespacing

2015-09-24 Thread Gregg Reynolds
Is there some compelling reason why deftype and defprotocol do not allow
specification of a namespace?  They install their products in the current
namespace, in contrast to gen-class and gen-interface.

Thanks
Gregg

-- 
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
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Core.matrix protocols for ND4J

2015-09-24 Thread Chris V. Nicholson
Hey folks - 

Just wanted to flag these core.matrix protocols for ND4J, which supports 
n-dimensional arrays and scientific computing more generally on the JVM. 

https://github.com/whilo/clj-nd4j
https://github.com/deeplearning4j/nd4j

If you have any questions, please let us know on Gitter:

https://gitter.im/deeplearning4j/deeplearning4j


-- 
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
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Immediate streaming of shell cmd stdout to a browser

2015-09-24 Thread Gary Verhaegen
Are you sure that the script itself is streaming its results? Shells
sometimes batch things when they detect they are not connected to a
tty.

On 24 September 2015 at 16:45, Karel Miarka  wrote:
> Hi,
>
> I want to run a long running bash script from a webapp and see it's
> continuous results on the page. I use conch to get the process' output
> stream and use this simple ring handler:
>
> (defn handler [req]
>   (response/response
> (let [p (sh/proc "/home/xyz/build.sh")]
>   (ring-io/piped-input-stream
> #(io/copy (:out p) % :buffer-size 1)))
> ...
>
> And run-jetty with :output-buffer-size 1 option, but the output is
> unfortunately displayed at once after the process finishes.
>
> Any idea?
>
> Thanks,
> Karel
>
> --
> 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
> ---
> You received this message because you are subscribed to the Google Groups
> "Clojure" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to clojure+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
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
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


core.typed and cider

2015-09-24 Thread JvJ
Hi,

Maybe this topic has already been addressed, but if it has been, I couldn't 
find it.

When using cider, I tend to user C-c C-l a lot to reload my namespaces as 
I'm writing them.

Is there an easy way to incorporate type-checking into this process?  A 
load-file-and-typecheck command?

I've already tried just putting (t/check-ns) at the end of the file, but 
this seems to cause stack overflows in some cases.

Thanks 

-- 
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
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


How to email PDF attachments

2015-09-24 Thread Jonathon McKitrick
I'm using clj-pdf to great success to stream a generated PDF when requested 
by URL, and postal to send email.

I now need to output the PDF to an attachment in the email itself, and this 
needs to be Heroku-capable (no local filesystem).

Has anyone done something similar, or any of the pieces?

-- 
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
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: How to email PDF attachments

2015-09-24 Thread Carlo Zancanaro
I don't know anything about your PDF/email problem, but I was under the
impression that you could use the local filesystem in Heroku, but that you
can't rely on it for persistance.

https://devcenter.heroku.com/articles/dynos#ephemeral-filesystem

So, if you had a solution that was "write to disk, then add file as an
attachment to an email" that could work on Heroku.

On 25 September 2015 at 10:13, Jonathon McKitrick 
wrote:

> I'm using clj-pdf to great success to stream a generated PDF when
> requested by URL, and postal to send email.
>
> I now need to output the PDF to an attachment in the email itself, and
> this needs to be Heroku-capable (no local filesystem).
>
> Has anyone done something similar, or any of the pieces?
>
> --
> 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
> ---
> You received this message because you are subscribed to the Google Groups
> "Clojure" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to clojure+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


cl-format bug?

2015-09-24 Thread jongwon . choi
(clojure.pprint/cl-format false "~A" :a)
=> ":a"   ;; instead of "a"

This happens in both Clojure 1.6 and 1.7. It is a bug, isn't it?

-- 
 
  Sydney, Australia

      
   
  

 

-- 
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
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: cl-format bug?

2015-09-24 Thread Andy Fingerhut
It is definitely the case that this behavior of cl-format you demonstrate
does not match the behavior of Common Lisp's format when given the same
arguments.  It doesn't capitalize the keyword name, either, but I think
leaving it lower case is more in keeping with Clojure's case-sensitive
symbol nature as opposed to Common Lisp's convert-to-caps behavior.

You can create a JIRA ticket if you wish:
http://dev.clojure.org/jira/browse/CLJ  ("Create Issue" link near top right
of page, after you sign in, creating an account if necessary).

Andy

On Thu, Sep 24, 2015 at 5:31 PM,  wrote:

> (clojure.pprint/cl-format false "~A" :a)
> => ":a"   ;; instead of "a"
>
> This happens in both Clojure 1.6 and 1.7. It is a bug, isn't it?
>
> 
>   Sydney, Australia
>
>     
> 
> 
> 
>
>
> --
> 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
> ---
> You received this message because you are subscribed to the Google Groups
> "Clojure" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to clojure+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.