ClojureScript on Windows

38 views
Skip to first unread message

rvdalen

unread,
Aug 24, 2022, 10:40:38 AM8/24/22
to ClojureScript
Hi everyone,

I am trying to get the most basic ClojureScript project up and running on Windows (not in WSL). 

I tried following the instructions on the Getting Started guide, but ran into trouble.

I could not download the cljs.jar file.  It seems the link in the guide is broken.
I had to scratch around to find the right cljs.jar file.  I downloaded the 1.11.4 cljs version.

After that I created the deps.edn file as described in the guide, and I run the cljs project with the command:

java -cp "cljs.jar;src/cljs;src/clj" cljs.main --compile mazes.core --repl

Things are working at this point, but I am now trying to add a dependency to dumdom in the deps.edn file, but the dependency files are not downloaded automatically.

I can get it working by manually downloading the dumdom.jar file and changing my run command to:

java -cp "cljs.jar;dumdom.jar;src/cljs;src/clj" cljs.main --compile mazes.core --repl

Can someone maybe explain how to get basic deps.edn to work without using Leiningen?

I just want a super simple ClojureScript project for messing around in the browser.

Regards
--Rouan

Gary Johnson

unread,
Aug 24, 2022, 11:36:40 AM8/24/22
to clojur...@googlegroups.com, rvdalen
rvdalen <rouan.v...@gmail.com> writes:
> I am trying to get the most basic ClojureScript project up and running
> on Windows (not in WSL).
>
> I tried following the instructions on the Getting Started guide, but
> ran into trouble.
>
> ...
>
> Can someone maybe explain how to get basic deps.edn to work without
> using Leiningen?

Hi Rouan,

The deps.edn file is used by the Clojure Tools CLI (not Leiningen).
You will need to install that program first.

https://clojure.org/guides/install_clojure

Once it is available on your shell's search path, simply calling
`clojure` with or without any arguments will read the deps.edn file and
download any dependencies listed within its `:deps` map to the
`.m2/repository` directory in your home directory. These will be
automatically added to your classpath when running the application
through `clojure`.

Good luck and happy hacking!
Gary

--
GPG Key ID: 7BC158ED
Use `gpg --search-keys lambdatronic' to find me
Protect yourself from surveillance: https://emailselfdefense.fsf.org
=======================================================================
() ascii ribbon campaign - against html e-mail
/\ www.asciiribbon.org - against proprietary attachments

Why is HTML email a security nightmare? See https://useplaintext.email/

Please avoid sending me MS-Office attachments.
See http://www.gnu.org/philosophy/no-word-attachments.html
Reply all
Reply to author
Forward
0 new messages