You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
<<clojure_cli#deps_tree,-X:deps tree>> Print deps tree
76
-
<<clojure_cli#deps_find_versions,-X:deps find-versions>> Find available versions of library
77
-
<<clojure_cli#deps_prep,-X:deps prep>> Prepare all unprepped libs in dep tree
76
+
<<clojure_cli#deps_find_versions,-X:deps find-versions>> Find available lib versions
77
+
<<clojure_cli#deps_prep,-X:deps prep>> Prepare all unprepped libs in deps
78
78
<<clojure_cli#deps_mvn_pom,-X:deps mvn-pom>> Generate pom.xml for deps.edn
79
79
<<clojure_cli#deps_mvn_install,-X:deps mvn-install>> Install maven jar to local repo
80
80
----
@@ -118,17 +118,13 @@ Function execution ultimately needs the following pieces of information:
118
118
* Qualified function to execute
119
119
* Map of key to value
120
120
121
-
122
-
123
121
`-X` <<clojure_cli#aliases,aliases>> can contain the following arg map keys:
124
122
125
123
* `:exec-fn` - a function symbol to use when none is supplied on the command line
126
124
* `:exec-args` - a map of key to value to include when `exec-fn` is executed, may be superseded by keyword args on the command line (so these act as defaults)
127
125
* `:ns-default` - default namespace symbol to use when interpreting the exec-fn
128
126
* `:ns-aliases` - map of alias symbol to namespace symbol to use when interpreting the exec-fn
129
127
130
-
131
-
132
128
[source,clojure]
133
129
----
134
130
;; deps.edn
@@ -216,6 +212,99 @@ __main-opts:__
216
212
217
213
See the <<repl_and_main#,clojure.main>> documentation for more details on main options.
218
214
215
+
[[options]]
216
+
== Options
217
+
218
+
[[opt_a]]
219
+
**-Aaliases**
220
+
221
+
`-A`
222
+
223
+
[[opt_x]]
224
+
**-X[aliases]**
225
+
226
+
[[opt_t]]
227
+
**-Ttoolname, -T[aliases]**
228
+
229
+
[[opt_m]]
230
+
**-M[aliases]**
231
+
232
+
[[opt_p]]
233
+
**-P**
234
+
235
+
Use `-P` before any of the other exec-opts (`-A`, `-X`, `-M`, `-T`) to do a full deps expansion, download deps, and cache the classpath, but not actually execute the function, tool, main, etc.
236
+
237
+
[[opt_j]]
238
+
**-Jopt**
239
+
240
+
Use `-J` to prefix any JVM option that should be provided to your program (the `-J` will be stripped). For example, `-J-Xmx1g` or `-J-XX:+HeapDumpOnOutOfMemoryError`.
241
+
242
+
[[opt_sdeps]]
243
+
**-Sdeps deps**
244
+
245
+
Use `-Sdeps` to supply an additional deps.edn source on the command line. This is used as the last <<clojure_cli#deps_sources,deps source>> in the merge. The deps data will need to be appropriately <<clojure_cli#quoting,quoted>> for the command line.
246
+
247
+
[[opt_srepro]]
248
+
**-Srepro**
249
+
250
+
Use `-Srepro` to omit the user deps.edn from the deps sources. This omits any user-specific configuration to ensure the command is repeatable for others.
251
+
252
+
Clojure <<clojure_cli#deps_sources,deps sources
253
+
254
+
[[opt_spath]]
255
+
**-Spath**
256
+
257
+
Use `-Spath` to compute and print the classpath.
258
+
259
+
[[opt_stree]]
260
+
**-Stree**
261
+
262
+
Use `-Stree` to compute and print the dependency tree. See the <<dep_expansion#_tree_printing,dependency expansion>> page for more information on the tree printing output.
263
+
264
+
[[opt_scp]]
265
+
**-Scp CP**
266
+
267
+
When this option is used, the classpath is not computed and the provided classpath is used instead. This is mostly useful in testing or debugging. In general, you should let the Clojure CLI compute (and cache) your classpath based on the deps.edn settings.
268
+
269
+
[[opt_sforce]]
270
+
**-Sforce**
271
+
272
+
This flag marks the existing cached classpath (if any) to be marked as stale. The classpath will be recomputed and cache.
273
+
274
+
[[opt_sverbose]]
275
+
**-Sverbose**
276
+
277
+
Print environment and path information found and used by the Clojure CLI, mostly useful for debugging the location of various config and cache directories.
278
+
279
+
This flag does not alter any other execution that may be specified on the command line, so it can be used to debug the location of the cache files for a particular command.
280
+
281
+
[[opt_sdescribe]]
282
+
**-Sdescribe**
283
+
284
+
Print configuration settings as edn data and exit. This overlaps in functionality with `-Sverbose` but may be useful for programmatic use.
285
+
286
+
[[opt_sthreads]]
287
+
**-Sthreads N**
288
+
289
+
By default, dep expansion will happen using a thread pool sized based on the processor count. Use this setting to change the number of threads used during expansion. Setting to 1 will do expansion serially with a single thread.
290
+
291
+
[[opt_strace]]
292
+
**-Strace**
293
+
294
+
The dependency tree printed by <<clojure_cli#opt_stree#`-Stree`>> or <<clojure_cli#deps_tree,`-X:deps tree`>> often contains sufficient information to debug why a particular lib or lib version was selected. However, if you need more information, this flag prints significantly larger information to a trace.edn file that can be used when filing an issue on tools.deps at https://ask.clojure.org[Ask Clojure].
295
+
296
+
[[opt_version]]
297
+
**--version, -version**
298
+
299
+
Prints the Clojure CLI version to either stdout (`--version`) or stderr (`-version`). Note that while the Clojure CLI version determines the default Clojure version used in execution, any version of the CLI can use any version of Clojure, and the Clojure version can be set in <<deps_edn#,deps.edn>> files to change that version.
300
+
301
+
See the <<xref/../../../releases/tools#,tools release>> page for more version and changelog information.
0 commit comments