Funny enough, that's exactly why the Clojure community created deps.edn [0].
- optional dependencies
- use JARs on disk, local projects that build JARs, or Maven Central
- pull in code from git repo via url and git hash or tag ("git dependencies")
- different variations for the above for different targets (run, test, integration-test, etc.)
[0]: https://clojure.org/guides/deps_and_cli