Re: Clojure Newbie questions

2016-05-04 Thread Mark Engelberg
For the most part, you can program complex programs in Clojure without ever dropping down to Java. There are only a handful of Java libraries that are important to know well, primarily because Clojure chose not to implement certain functionality that is readily available on the host system.

Re: Clojure Newbie questions

2016-05-04 Thread Leif
Hi, Bruce. I know almost no Java, and yet I have been a fairly productive professional Clojure programmer for several years. How is that possible? Here are my thoughts: 1. A lot of code is application logic. This will be 100% Clojure. 2. The next big chunk of code is talking to databases,

Re: Clojure Newbie questions

2016-05-04 Thread Arnaud BOS
At last a question I can contribute to. There's certainly no need to be a Java "guru" to become "good" at Clojure, although it depends on what you definition of "being good at something" is. I'm far from being a Java guru, really, I've learned it only 8 years ago (at school) and only practiced

Clojure Newbie questions

2016-05-04 Thread Bruce Whealton
Hello, There is much I like about Clojure - from it being a Lisp dialect to functional programming. I know it runs on the JVM. My question is this: If one is not a guru with Java will that be a problem becoming good at Clojure? The only thing that intimidates me about Java is the

Newbie questions: include external libraries from lein REPL

2013-11-07 Thread Starry SHI
Hi. I am new to clojure, and I find leiningen REPL is a convenient tool for clojure code testing. However, I find I cannot include external java libraries and call functions defined in those libraries from lein REPL. For example, my clojure code needs to compute square root, which is defined

Re: Newbie questions: include external libraries from lein REPL

2013-11-07 Thread Cedric Greevey
Assuming the Java or Clojure library is on your classpath, it *should* be usable from the REPL. (import '[java.library SomeClass]) (.foo (SomeClass. 42)) (require '[clojure.contrib.math :as m]) (m/sqrt 42.0) or whatever On Thu, Nov 7, 2013 at 8:00 AM, Starry SHI starr...@gmail.com wrote:

newbie questions about evaluation and -main

2012-10-08 Thread Brian Craft
I started with a db example and dropped this into the core.clj of an 'app' project, just before the defn for -main. (sql/with-connection db (sql/with-query-results rs [select * from foo limit 3] (dorun (map #(println %) rs On lein run this prints three rows, but prints them twice. If

Re: newbie questions

2011-08-31 Thread Vincent
try out clooj ide ... if never used emacs , -- 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

Re: newbie questions

2011-08-31 Thread Phil Hagelberg
On Tue, Aug 30, 2011 at 1:32 PM, labwor...@gmail.com wrote: (1) I have followed the Getting started steps and installed clojure-mode in Emacs. However, when I edit a .clj file, I am in clojure-mode (C-h m) but no clojure on the menubar. There should be one, right? What am i missing. There's

newbie questions

2011-08-30 Thread labwork07
(1) I have followed the Getting started steps and installed clojure-mode in Emacs. However, when I edit a .clj file, I am in clojure-mode (Ch m) but no clojure on the menubar. There should be one, right? What am i missing. (2) I just use Mx inferior-lisp. But how do you get out of clojure? I

Re: newbie questions

2011-08-30 Thread Mark Nutter
There are some old Getting Started steps out there, but you'll probably get a better start if you Google for leiningen and swank-clojure for a more up-to-date technique. If you need to tell the Clojure process to quit, the syntax is (System/exit 0). Mark On Tue, Aug 30, 2011 at 4:32 PM,

Re: Newbie questions about leiningen

2010-07-07 Thread songoku
Thanks for both answers. Two ways of doing it. Great! The :jvm-opts -Xmx1g -option in the project-file doesnt seem to work with the swank-server. -- You received this message because you are subscribed to the Google Groups Clojure group. To post to this group, send email to

Re: Newbie questions about leiningen

2010-07-03 Thread Saul Hazledine
On Jul 2, 6:35 pm, Nicolas Oury nicolas.o...@gmail.com wrote: I am looking for a way to tell leiningen what JVM options to use with the SWANK server. (I need a lot of Heap size to do anything useful...) I wasn't able to find that in the doc. Is it not the right way of proceeding? I'd

Re: Newbie questions about leiningen

2010-07-03 Thread Nicolas Oury
Thanks for both answers. Two ways of doing it. Great! On Sat, Jul 3, 2010 at 9:56 AM, Saul Hazledine shaz...@gmail.com wrote: On Jul 2, 6:35 pm, Nicolas Oury nicolas.o...@gmail.com wrote: I am looking for a way to tell leiningen what JVM options to use with the SWANK server. (I need a lot

Newbie questions about leiningen

2010-07-02 Thread Nicolas Oury
Dear all, I am moving from netbeans to leiningen + swank + emacs. Enclojure was great but I wanted to try somnething else. Leiningen is amazing. Thanks to the author(s). I am looking for a way to tell leiningen what JVM options to use with the SWANK server. (I need a lot of Heap size to do

Re: Newbie questions about leiningen

2010-07-02 Thread Moritz Ulrich
If you launch swank with 'lein swank', there is probably an option. lein is just a shell-script which calls the following at the end: exec $RLWRAP $JAVA_CMD -Xbootclasspath/a:$CLOJURE_JAR -client $JAVA_OPTS \ -cp $CLASSPATH -Dleiningen.version=$VERSION $JLINE \

Compilation and Class Generation newbie questions

2010-02-15 Thread Paulo Sérgio Medeiros
Hello everyone, I think i've not figured out yet how compile and/or namespace works. I'm trying to execute the example posted in http://clojure.org/compilation I've created a file named hello.clj and put the clojure.jar in the same directory (c:\clojure_tests). Then, i started the REPL using

Re: Compilation and Class Generation newbie questions

2010-02-15 Thread Alex Ott
Hello If you declared clojure.examples.hello namespace, then you need to have file hello.clj in clojure/examples/ directory. and you need to have c:\clojure_tests in classpath, something like: java -cp clojure.jar:c:\clojure_tests clojure.main Paulo Sérgio Medeiros at Mon, 15 Feb 2010 03:13:51

Re: Compilation and Class Generation newbie questions

2010-02-15 Thread Meikel Brandmeyer
Hi, On Feb 15, 6:13 am, Paulo Sérgio Medeiros pase...@gmail.com wrote: I think i've not figured out yet how compile and/or namespace works. I'm trying to execute the example posted inhttp://clojure.org/compilation I've created a file named hello.clj and put the clojure.jar in the same

Re: Compilation and Class Generation newbie questions

2010-02-15 Thread Paulo Sérgio Medeiros
Hi! Thanks, i think i haven't executed java from command line for a while and forgot some things. ;-) On Mon, Feb 15, 2010 at 11:32 AM, Meikel Brandmeyer m...@kotka.de wrote: Hi, On Feb 15, 6:13 am, Paulo Sérgio Medeiros pase...@gmail.com wrote: I think i've not figured out yet how compile

Re: Classes and Clojure reader (newbie questions)

2008-12-28 Thread TPJ
(...) This is perfectly possible, although not necessarily desirable. (ns com.example.MyClass    (:gen-class      :state state      :init init      :methods [[getMyIntField [] Integer]                [setMyIntField [Integer] Void/TYPE]])) (defn -init    [x]    [[] (ref x)]) (defn