I'm new at clojure+emacs+slime+swank+leiningen and I wanted to run a
(simple?) test that goes like this:

$ lein new test-project; cd test-project
$ cat > ./src/core.clj
(ns test-project.core)

(def *argh* 1)

; loop, printing *argh* every sec, for 100 secs
(loop [i 0]
  (if (= i 100)
    (println "OK.")
    (do
      (println *argh*)
      (. Thread (sleep 1000))
      (recur (+ i 1)))))

Then, to test core.clj, I ran it from the command line:
$ clj ./src/core.clj
1
1
1
etc.
OK.


Then, I did:
$ lein swank
user=> Connection opened on local port  4005
#<ServerSocket ServerSocket[addr=localhost/
127.0.0.1,port=0,localport=4005]>

First question: why no visible output?


Still hoping, I launched emacs (actually Aquamacs, cuz I'm not that
comfortable with yanking) and:
1. opened test-project/src/test_project/core.clj


2. M-x slime-connect
Versions differ: 2010-09-22 (slime) vs. 20100404 (swank). Continue? (y
or no)

Hem. Why that? Plus, no output in the slime buffer. Just an REPL
prompt. And a non-responsive one at that (I can type but nothing that
I type is interpreted). So, just a prompt, really.


3. in the core.clj buffer, changed value of *arhg* to 2, placed cursor
at the end of this, and evaluated the expression (^X ^E). No change on
the slime-repl clojure side.


I realize how little I understand about all this but would love to get
started. Any advice much appreciated.


Thanks
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 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

Reply via email to