The REPL helpers a project created by wagoe new gets.
bb quickstart has always closed with "run (status), run (commands)", and
until BOU-319 neither existed outside this monorepo: the generated
dev/user.clj was thirteen lines of go/reset/halt, so the first instruction a
new user follows answered Unable to resolve symbol: status.
The implementations live here rather than in the template because a template is not compiled by anything until someone generates a project and boots it. dev/user.clj is a thin delegation layer over these, and these are tested.
Shell: reads the running system, asks Jetty for its port, prints. The formatting and the module detection are in the core namespace of the same name.
The REPL helpers a project created by `wagoe new` gets. `bb quickstart` has always closed with "run (status), run (commands)", and until BOU-319 neither existed outside this monorepo: the generated dev/user.clj was thirteen lines of go/reset/halt, so the first instruction a new user follows answered `Unable to resolve symbol: status`. The implementations live here rather than in the template because a template is not compiled by anything until someone generates a project and boots it. dev/user.clj is a thin delegation layer over these, and these are tested. Shell: reads the running system, asks Jetty for its port, prints. The formatting and the module detection are in the core namespace of the same name.
(base-url system config)The URL you can open, from the running server rather than the config.
Two things the config cannot tell you. The port: auto-find moves the app off
an occupied 3000, and printing the configured port then sends the user to a
dead address. The host: 0.0.0.0 is what the server binds, not something a
browser can open. And ig-config folds the :wagoe/http block into
:wagoe/http-server, so the key the first version of this read did not
exist in the Integrant config at all.
The URL you can open, from the running server rather than the config. Two things the config cannot tell you. The port: auto-find moves the app off an occupied 3000, and printing the configured port then sends the user to a dead address. The host: `0.0.0.0` is what the server binds, not something a browser can open. And `ig-config` folds the `:wagoe/http` block into `:wagoe/http-server`, so the key the first version of this read did not exist in the Integrant config at all.
(commands)Print the commands this project has.
Print the commands this project has.
(config)(config section)The running config. With a section keyword, print that section as a tree with secrets redacted.
The running config. With a section keyword, print that section as a tree with secrets redacted.
(fix!)(fix! exception)Apply the suggested fix for the last error, if there is one.
(fix!) — the last error the REPL saw (fix! ex) — a specific exception
Apply the suggested fix for the last error, if there is one. (fix!) — the last error the REPL saw (fix! ex) — a specific exception
(handle-error! e)Run the error pipeline on e and remember it for (fix!).
dev/user.clj calls this from the catch of (go) and (reset): without it nothing ever populates the last-exception the zero-arity (fix!) reads, and (fix!) can only ever answer "no recent error".
Run the error pipeline on `e` and remember it for (fix!). dev/user.clj calls this from the catch of (go) and (reset): without it nothing ever populates the last-exception the zero-arity (fix!) reads, and (fix!) can only ever answer "no recent error".
(modules)Active application modules, as a vector of names.
Active application modules, as a vector of names.
(routes)(routes filter-key)Print the HTTP routes of the running system, optionally filtered by module keyword or path string.
Print the HTTP routes of the running system, optionally filtered by module keyword or path string.
(status)Print system health: components, URL, active modules.
Print system health: components, URL, active modules.
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |