tools-deps

mwolf 2024-09-04T23:17:50.481629Z

what is the equivalent java command line call to something like clojure -X some.package/proc :arg 123, e.g. something like java -cp $(clojure -Spath) clojure.main <something>? a stacktrace led back to clojure.main/main, I'm just haven't dug in enough to figure out the args.

seancorfield 2024-09-04T23:20:43.384459Z

-X goes thru a different entry point altogether, that handles the EDN formatted arguments and builds a hash map and then invokes a function.

seancorfield 2024-09-04T23:23:03.614379Z

I believe it relies on being invoked by the Clojure CLI script, for things like reading the basis (from .cpcache), so you can't quite run it standalone.

seancorfield 2024-09-04T23:32:23.463019Z

(and clojure.run.exec is only on the classpath for the Clojure CLI I think?)

Alex Miller (Clojure team) 2024-09-04T23:40:28.692989Z

Correct

Alex Miller (Clojure team) 2024-09-04T23:41:51.488839Z

The -X/-T entry point is injected by the CLI and that shim is intentionally not easily available separately because it has continued to evolve over the years. I would eventually like to call it stable and either add it to core or in a separate lib

Alex Miller (Clojure team) 2024-09-04T23:42:48.032269Z

It has significantly benefitted from being able to evolve but the pace of change has gone way down

mwolf 2024-09-04T23:43:53.979129Z

'k -- thanks. it was one of those "how could I get this weird thing to work?" experiments.