id = "clojure"
name = "Clojure CLI"
homepage = "https://clojure.org/reference/clojure_cli"
description = "Command line tools to run a Clojure REPL or program and manage dependencies declared in deps.edn."
icon = "theSVG:clojure"
executables = ["clojure"]
[dotfiles]
paths = [
"~/.clojure/deps.edn",
"~/.clojure/tools/",
"[configHome]/clojure/deps.edn",
"[configHome]/clojure/tools/",
]
exclude = [
"~/.clojure/.cpcache/",
"[configHome]/clojure/.cpcache/",
]
secret = []
side_effect = false
[commands]
format = 1
label = "Run Clojure"
description = "Evaluate an expression, run a namespace's -main, or start a REPL with the Clojure CLI. Aliases, -X/-T function invocation and -S dependency flags are left out."
quality = "ai-draft"
base = "fig:clojure"
parser = { end_of_options = "--", interleave = "permute", long_equals = true, short_attached = true, short_bundles = false }
[[commands.source]]
id = "fig"
kind = "completion"
url = "https://github.com/withfig/autocomplete/blob/master/src/clojure.ts"
license = "MIT"
[[commands.field]]
id = "eval"
label = "Expression"
description = "Evaluate expressions in this string and print non-nil values."
type = "string"
option = ["--eval", "-e"]
sources = ["fig"]
[[commands.field]]
id = "main"
label = "Main namespace"
description = "Call the -main function of this namespace."
type = "string"
option = ["--main", "-m"]
sources = ["fig"]
[[commands.field]]
id = "init"
label = "Init file"
description = "Load a file or resource before running."
type = "path"
option = ["--init", "-i"]
path = { kind = "file", role = "input" }
sources = ["fig"]
[[commands.field]]
id = "repl"
label = "Run a REPL"
type = "boolean"
option = ["--repl", "-r"]
sources = ["fig"]
[[commands.field]]
id = "prepare"
label = "Prepare deps only"
description = "Download libs and cache the classpath without executing."
type = "boolean"
option = ["-P"]
sources = ["fig"]
[[commands.field]]
id = "classpath_only"
label = "Print classpath"
type = "boolean"
option = ["-Spath"]
sources = ["fig"]
[[commands.field]]
id = "tree"
label = "Print dependency tree"
type = "boolean"
option = ["-Stree"]
sources = ["fig"]
[[commands.field]]
id = "force"
label = "Force classpath recomputation"
type = "boolean"
option = ["-Sforce"]
sources = ["fig"]
[[commands.task]]
id = "repl"
label = "Start a REPL"
set = { repl = [true] }
fields = ["repl", "init"]
required = []
[[commands.task]]
id = "eval"
label = "Evaluate an expression"
fields = ["eval", "init"]
required = ["eval"]
[[commands.task]]
id = "main"
label = "Run a namespace"
fields = ["main"]
required = ["main"]
[[commands.group]]
id = "basic"
label = "Basic"
fields = ["eval", "main", "init", "repl"]
[[commands.group]]
id = "advanced"
label = "Dependencies"
fields = ["prepare", "classpath_only", "tree", "force"]