33
44# Set bash instead of sh for the @if [[ conditions,
55# and use the usual safety flags:
6- SHELL = /bin/bash -Ee
6+ SHELL = /bin/bash -Eex
77
88CLOJURE_VERSION ?= 1.12
9+ NREPL_VERSION ?= 1.4
10+ COMMON_PROFILES = "+$(CLOJURE_VERSION ) ,+nrepl-$(NREPL_VERSION ) "
911TEST_PROFILES ?= "-user,-dev,+test"
1012
1113# We need Java sources to test Java parsing functionality, but the Docker images
@@ -39,42 +41,40 @@ target/srcdeps: project.clj
3941# Remove cljfmt.main because it depends on tools.cli which we explicitly removed.
4042 rm -f target/srcdeps/cider/nrepl/inlined/deps/cljfmt/*/cljfmt/main.clj
4143
42- test_impl : copy-sources-to-jdk
43- lein with-profile $(TEST_PROFILES ) ,+ $( CLOJURE_VERSION ) test
44+ quick-test : copy-sources-to-jdk
45+ lein with-profile $(COMMON_PROFILES ) , $( TEST_PROFILES ) test
4446
4547test : target/srcdeps
46- @make test_impl TEST_PROFILES=" $( TEST_PROFILES) ,+plugin.mranderson/config"
47-
48- quick-test : test_impl
48+ lein with-profile $(COMMON_PROFILES ) ,$(TEST_PROFILES ) ,+plugin.mranderson/config test
4949
5050eastwood :
51- lein with-profile -user,-dev,+ $( CLOJURE_VERSION ) ,+deploy,+eastwood eastwood
51+ lein with-profile -user,-dev,$( COMMON_PROFILES ) ,+deploy,+eastwood eastwood
5252
5353cljfmt :
54- lein with-profile -user,-dev,+ $( CLOJURE_VERSION ) ,+cljfmt cljfmt check
54+ lein with-profile -user,-dev,$( COMMON_PROFILES ) ,+cljfmt cljfmt check
5555
5656cljfmt-fix :
57- lein with-profile -user,-dev,+ $( CLOJURE_VERSION ) ,+cljfmt cljfmt fix
57+ lein with-profile -user,-dev,$( COMMON_PROFILES ) ,+cljfmt cljfmt fix
5858
5959.make_kondo_prep : project.clj .clj-kondo/config.edn
60- CIDER_NO_MRANDERSON=" true" CIDER_NO_PEDANTIC=" true" lein with-profile -user,-dev,+test,+clj-kondo,+deploy,+ $( CLOJURE_VERSION ) clj-kondo --copy-configs --dependencies --lint ' $$classpath' > $@
60+ CIDER_NO_MRANDERSON=" true" CIDER_NO_PEDANTIC=" true" lein with-profile -user,-dev,+test,+clj-kondo,+deploy,$( COMMON_PROFILES ) clj-kondo --copy-configs --dependencies --lint ' $$classpath' > $@
6161
6262kondo : .make_kondo_prep clean
63- CIDER_NO_MRANDERSON=" true" CIDER_NO_PEDANTIC=" true" lein with-profile -user,-dev,+test,+clj-kondo,+deploy,+ $( CLOJURE_VERSION ) clj-kondo
63+ CIDER_NO_MRANDERSON=" true" CIDER_NO_PEDANTIC=" true" lein with-profile -user,-dev,+test,+clj-kondo,+deploy,$( COMMON_PROFILES ) clj-kondo
6464
6565lint : kondo cljfmt eastwood
6666
6767# PROJECT_VERSION=x.y.z make install
6868install : dump-version check-install-env target/srcdeps
69- CIDER_NO_PEDANTIC=" true" lein with-profile -user,-dev,+ $( CLOJURE_VERSION ) ,+plugin.mranderson/config install
69+ CIDER_NO_PEDANTIC=" true" lein with-profile -user,-dev,$( COMMON_PROFILES ) ,+plugin.mranderson/config install
7070
7171# PROJECT_VERSION=x.y.z make fast-install
7272fast-install : dump-version check-install-env
73- lein with-profile -user,-dev,+ $( CLOJURE_VERSION ) install
73+ lein with-profile -user,-dev,$( COMMON_PROFILES ) install
7474
7575smoketest : install
7676 cd test/smoketest && \
77- lein with-profile -user,-dev,+$(CLOJURE_VERSION ) uberjar && \
77+ lein with-profile -user,-dev,$(COMMON_PROFILES ) uberjar && \
7878 java -jar target/smoketest-0.1.0-SNAPSHOT-standalone.jar
7979
8080# Deployment is performed via CI by creating a git tag prefixed with "v".
@@ -87,7 +87,7 @@ deploy: check-env target/srcdeps
8787 rm -f .no-mranderson
8888 export PROJECT_VERSION=$$(echo "$(CIRCLE_TAG ) " | sed 's/^v//' ) ; \
8989 echo " \" $$ PROJECT_VERSION\" " > resources/cider/nrepl/version.edn; \
90- lein with-profile -user,-dev,-provided,+ $( CLOJURE_VERSION ) ,+plugin.mranderson/config deploy clojars
90+ lein with-profile -user,-dev,-provided,$( COMMON_PROFILES ) ,+plugin.mranderson/config deploy clojars
9191
9292check-env :
9393ifndef CLOJARS_USERNAME
0 commit comments