Fork me on GitHub
#circleci
<
2020-07-03
>
jr0cket15:07:39

@seancorfield I am assuming the following command just downloads project dependencies and prints out the classpath to avoid doing anything else, similar to doing lein deps without running anything else.

clojure -R:test:runner -Spath
Full context, its used in a CircleCI step in https://github.com/seancorfield/next-jdbc/blob/develop/.circleci/config.yml#L13 Just checking if I understood this correctly. Thanks.

seancorfield16:07:24

Yes @jr0cket -- Using -R instead of -A means that just the "resource" portion of those aliases is used (in particular :main-opts is ignored) and -Spath is basically a throwaway to avoid clojure running any code or starting a REPL. -e nil is another possibility (that wouldn't print anything -- but I find either -Spath or -Stree can be a useful debugging aid to double-check dependencies are correct).

jr0cket17:07:03

Thanks for confirming, yes that all makes sense. I like the idea of having more debugging info. I have a nice simple config.yml file working, which uses an image with the latest release of Clojjure CLI tools and OpenJDK 11. https://github.com/practicalli/random-clojure-function/blob/live/.circleci/config.yml I'll build on that config and add more features as needed. Probably the next thing is to deploy apps to Heroku on successful build of live branch. CircleCI is really simple to use compared to the corporate configuration of TeamCity I spent several weeks configuring in a bank :)

seancorfield17:07:46

I find GitHub Actions even simpler (but less sophisticated). Several of my projects have both.

seancorfield17:07:21

With GHA it is trivial to have matrix testing over a variety of JDK versions. With CircleCI it is possible but a lot more work.