day8 / re-frame-template

A Leiningen template for creating a re-frame application (client only) with a shadow-cljs build.
MIT License
587 stars 90 forks source link

Installation instructions for newbies #131

Closed martimatix closed 4 years ago

martimatix commented 4 years ago

It'd be nice to add some installation instructions for newbies. Maybe it's common knowledge among Clojurists that to install a lein script, you need to add it to ~/.m2 but for those that don't, some research is required.

mike-thompson-day8 commented 4 years ago

@martimatix Could you give a more concrete example, please? I'm not understanding what you mean by "installation instructions".

Do you mean something like this: https://purelyfunctional.tv/guide/how-to-install-clojure/

martimatix commented 4 years ago

Suppose you're brand new to the world of Clojure and Clojurescript. You've read about the new re-frame design on reddit. You start reading about re-frame and you're sold. "I want to get started," you think to yourself. You go to the Start Coding page and see that there's a template to scaffold your project (this repo).

You're on a Mac and have run brew install clojure but don't really know much about Clojure or Leiningen.

You click on the link to this repo and start reading the readme. You read that you need to run lein new re-frame <project-name> but how do you install it? That is to say, if I run git clone https://github.com/day8/re-frame-template.git in any old directory, Leiningen won't be able to find it.

For the sake of Clojurescript newbies, I was suggesting that something like this be added:

  1. clone this repo
  2. copy src/leiningen/new to ~/.m2/repository (by the way, is there an easier way?)

That was a long winded way of describing the situation that I found myself in. I ended up having to search for installing Leiningen templates and found this page.

Going through this experience prompted me to open this issue.

martimatix commented 4 years ago

Never mind, turns out that you don't need to clone this repo at all. 🤦‍♂️

lein new re-frame <project-name> is all you need.

mike-thompson-day8 commented 4 years ago

I'm glad you worked it out.

But you got me thinking, and I added this to the README https://github.com/day8/re-frame-template/blob/master/README.md#before-you-start.