Skip to content

Commit 0f3254a

Browse files
committed
make default_cols consistent to avoid ci surprises
1 parent 44edcf3 commit 0f3254a

File tree

2 files changed

+2
-6
lines changed

2 files changed

+2
-6
lines changed

cli/stat.go

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,7 @@ import (
1313

1414
func (*RootCmd) stat() *clibase.Cmd {
1515
fs := afero.NewReadOnlyFs(afero.NewOsFs())
16-
defaultCols := []string{"host_cpu", "host_memory", "home_disk"}
17-
if ok, err := clistat.IsContainerized(fs); err == nil && ok {
18-
// If running in a container, we assume that users want to see these first. Prepend.
19-
defaultCols = append([]string{"container_cpu", "container_memory"}, defaultCols...)
20-
}
16+
defaultCols := []string{"host_cpu", "host_memory", "home_disk", "container_cpu", "container_memory"}
2117
formatter := cliui.NewOutputFormatter(
2218
cliui.TableFormat([]statsRow{}, defaultCols),
2319
cliui.JSONFormat(),

docs/cli/stat.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ coder stat [flags]
1717
| | |
1818
| ------- | -------------------------------------------------------------------------- |
1919
| Type | <code>string-array</code> |
20-
| Default | <code>container_cpu,container_memory,host_cpu,host_memory,home_disk</code> |
20+
| Default | <code>host_cpu,host_memory,home_disk,container_cpu,container_memory</code> |
2121

2222
Columns to display in table output. Available columns: host cpu, host memory, home disk, container cpu, container memory.
2323

0 commit comments

Comments
 (0)