@@ -4,14 +4,24 @@ Beauty is in the eye of the beholder; `cli-tools` makes a default
44set of choices for what kind of colors and fonts to use
55for its output, but this can be overridden.
66
7- The ` net.lewisship.cli-tools.styles ` contains a dynamic var, ` *default-styles* ` , that is used by the rest of ` cli-tools `
8- when
9- formatting output. By overriding or rebinding this var, the fonts can be overridden .
7+ Styles are defined by two vars in namespace ` net.lewisship.cli-tools.styles ` ; each is a
8+ map from a usage name (such as : tool-name-label ) to a
9+ [ font definition ] ( https://cljdoc.org/d/org.clj-commons/pretty/3.6.7/api/clj-commons.ansi#compose ) .
1010
11- The most common to override are:
11+ * ` default-styles ` are the defaults for all usages
12+ * ` *style-overrides* ` contains overrides for ` default-styles ` (and is dynamic)
1213
13- - : tool-name-label (default : bold .green) used when writing the name of the tool itself
14+ By overriding or rebinding this var, the fonts can be overridden.
15+
16+ The most common usages to override are:
17+
18+ - : tool-name (default : bold .green) used when writing the name of the tool itself
1419- : command-path (default : bold .green) used when writing the command path
1520
16- When overriding ` *default-styles* ` , you can just provide overrides of what's in ` default-styles ` ; anything not found in
17- the dynamic var is then searched for in the non-dynamic var.
21+ Example:
22+
23+ ``` clojure
24+ (binding [style/*style-overrides* {:tool-name :inverse.bold }]
25+ (cli-tools/dispatch { ... }))
26+
27+ ```
0 commit comments