@@ -19,15 +19,73 @@ Then kubecolor will translate that to the following kubectl invokation:
1919kubectl get pods --namespace=kube-system
2020```
2121
22+ ::: caution
23+ Due to techinical limitations the kubecolor command-line flag values must be
24+ specified in the same string as ` --flag=value ` .
25+
26+ ``` bash
27+ # good:
28+ kubecolor --kubecolor-stdin=foo
29+ kubecolor --pager=foo
30+
31+ # bad:
32+ kubecolor --kubecolor-stdin foo
33+ kubecolor --pager foo
34+ ```
35+ :::
36+
2237## ` --kubecolor-version `
2338
2439Prints the version of kubecolor (not kubectl one).
2540
41+ ## ` --kubecolor-stdin `
42+
43+ Don't run ` kubectl ` but instead only parse and print. Works as a sort of
44+ "dry run" for kubecolor coloring. The arguments for the kubecolor command
45+ (such as ` get pods ` or ` describe pod ` ) still matters as they tell kubecolor
46+ how to parse and colorize the output.
47+
48+ By default if you only supply the ` --kubecolor-stdin ` flag with no value then
49+ it will read from stdin. Example:
50+
51+ ``` bash
52+ kubectl get pods > results.txt
53+ cat results.txt | kubecolor get pods --kubecolor-stdin
54+ ```
55+
56+ Alternatively you can provide a path from which kubecolor will read from that
57+ file instead of from stdin:
58+
59+ ``` bash
60+ kubectl get pods > results.txt
61+ kubecolor get pods --kubecolor-stdin=results.txt
62+ ```
63+
64+ You can use this feature to colorize any arbitrary output, such as using
65+ kubecolor's log parsing and colorizing on Docker logs:
66+
67+ ``` bash
68+ docker logs my-container | kubecolor logs --kubecolor-stdin
69+ ```
70+
2671## ` --light-background `
2772
2873When your terminal's background color is something light (e.g white), default color preset might look too bright and not readable.
2974If so, specify ` --light-background ` as a command line argument. kubecolor will use a color preset for light-background environment.
3075
76+ This is an alias for ` --kubecolor-theme=light `
77+
78+ ## ` --kubecolor-theme `
79+
80+ Sets the kubecolor color theme preset. You must provide a value for this flag,
81+ like so:
82+
83+ ``` bash
84+ kubecolor get pods --kubecolor-theme=dark
85+ ```
86+
87+ See: [ Customizing / Color themes] ( /customizing/themes/ )
88+
3189## ` --force-colors `
3290
3391By default, kubecolor never output the result in colors when the tty is not a terminal standard output.
@@ -36,7 +94,7 @@ For example, when you want to pass kubecolor result to grep (e.g `kubecolor get
3694It supports multiple values in the form of ` --force-colors=... ` .
3795Just specifying ` --force-colors ` is the same as ` --force-colors=auto ` .
3896
39- See [ Dynamic color support] ( #dynamic-color-support ) section for all possible values.
97+ See: [ Usage / How it works # Dynamic color support] ( /usage/how-it-works/ #dynamic-color-support)
4098
4199## ` --plain `
42100
0 commit comments