Skip to content

Instantly share code, notes, and snippets.

@nbardiuk
Last active Oct 14, 2020
Embed
What would you like to do?
Clojure tdd (test watch) using headless lein and rep
.PHONY: tdd
tdd: .nrepl-port
watchexec --clear --no-shell rep '(repl/refresh)(doto "$(only)" (run-tests))'
.PHONY: kill-repl
kill-repl:
@if [ -f .nrepl-port ];\
then\
kill $$(lsof -ti ":$$(cat .nrepl-port)" -sTCP:LISTEN) ;\
fi
.nrepl-port:
lein repl :headless &
@until [ -f .nrepl-port ] ; do sleep 1; done
@nbardiuk
Copy link
Author

nbardiuk commented Oct 14, 2020

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment