v0.34.0 doc sweep and update

This commit is contained in:
lixen committed 2026-10-11 03:27:10 -04:00
1 parent 87f5576ccf
commit 1abffcec6c
41 files changed
+1447 -2287

No files matched your search

+1 -1
View File
@@ -109,7 +109,7 @@ func (a *app) items(n compose.Node, path string) []string {
// placeholder says what an unset key means: its default, what zero means, or
// the kind of value it takes
func placeholder(k config.Key) string {
if k.Zero != "" {
if k.Zero != "" && k.Default == "" {
return "(" + k.Zero + ")"
}
return cmp.Or(k.Default, k.Hint)
+10
View File
@@ -249,6 +249,16 @@ func TestInspectorHelpSitsUnderItsKeys(t *testing.T) {
}
}
// An unset key shows its default, what zero means when it has none, or the
// kind of value it takes
func TestAnUnsetKeyShowsItsDefaultFirst(t *testing.T) {
for want, k := range map[string]config.Key{"168": {Default: "168", Zero: "kept"}, "(off)": {Zero: "off"}, "dir": {Hint: "dir"}} {
if got := placeholder(k); got != want {
t.Errorf("%+v shows %q, want %q", k, got, want)
}
}
}
// Hints follow their text, three columns on, not the screen's far edge: the
// keys after the status, the bar's verbs after the pipelines
func TestHintsFollowTheirText(t *testing.T) {