Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion cmd/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,8 @@ const (
KeyTelemetry ConfigKey = "telemetry"
KeyExperiments ConfigKey = "experiments"
KeyCredentialStore ConfigKey = "credential_store"
KeyLogCacheURL ConfigKey = "log_cache_url"
KeyLogMaxBytes ConfigKey = "log_max_bytes"
)

// AllKeys returns all valid configuration keys
Expand All @@ -61,6 +63,8 @@ func AllKeys() []ConfigKey {
KeyTelemetry,
KeyExperiments,
KeyCredentialStore,
KeyLogCacheURL,
KeyLogMaxBytes,
}
}

Expand All @@ -81,7 +85,7 @@ func (k ConfigKey) IsLocalOnly() bool {
// IsUserOnly returns true if the key can only be set in user config
func (k ConfigKey) IsUserOnly() bool {
switch k {
case KeyNoInput, KeyPager, KeyTelemetry, KeyExperiments, KeyCredentialStore:
case KeyNoInput, KeyPager, KeyTelemetry, KeyExperiments, KeyCredentialStore, KeyLogCacheURL, KeyLogMaxBytes:
return true
default:
return false
Expand Down Expand Up @@ -156,6 +160,10 @@ func SetConfigValue(conf *config.Config, key ConfigKey, value string, local bool
return conf.SetExperiments(value)
case KeyCredentialStore:
return conf.SetCredentialStore(value)
case KeyLogCacheURL:
return conf.SetLogCacheURL(value)
case KeyLogMaxBytes:
return conf.SetLogMaxBytes(value)
}

return nil
Expand Down
2 changes: 2 additions & 0 deletions cmd/config/config_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ func TestValidateKey(t *testing.T) {
"pager",
"experiments",
"credential_store",
"log_cache_url",
"log_max_bytes",
}

for _, key := range validKeys {
Expand Down
8 changes: 8 additions & 0 deletions cmd/config/get.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ Valid keys:
pager Custom pager command
experiments Enabled experiment flags
credential_store Default credential store for tokens (auto, keyring, shm)
log_cache_url Parquet log cache URL (file://, s3://)
log_max_bytes Maximum job log size in bytes (0 disables limit)

Examples:
$ bk config get output_format
Expand Down Expand Up @@ -75,6 +77,12 @@ func (c *GetCmd) Run() error {
value = conf.Experiments()
case KeyCredentialStore:
value = conf.CredentialStore()
case KeyLogCacheURL:
value = conf.LogCacheURL()
case KeyLogMaxBytes:
if maxBytes, configured := conf.LogMaxBytes(); configured {
value = fmt.Sprintf("%d", maxBytes)
}
}

if value != "" {
Expand Down
6 changes: 6 additions & 0 deletions cmd/config/list.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,12 @@ func (c *ListCmd) Run() error {
if v := conf.CredentialStore(); v != "" && v != keyring.StoreAuto {
items = append(items, configItem{string(KeyCredentialStore), v, "effective"})
}
if v := conf.LogCacheURL(); v != "" {
items = append(items, configItem{string(KeyLogCacheURL), v, "effective"})
}
if maxBytes, configured := conf.LogMaxBytes(); configured {
items = append(items, configItem{string(KeyLogMaxBytes), fmt.Sprintf("%d", maxBytes), "effective"})
}
}

if c.Local && !inGitRepo {
Expand Down
7 changes: 6 additions & 1 deletion cmd/config/set.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ Valid keys:
pager Custom pager command [user config only]
telemetry Enable anonymous usage telemetry (true, false) [user config only]
credential_store Default credential store for tokens (auto, keyring, shm) [user config only]
log_cache_url Parquet log cache URL (file://, s3://; empty uses ~/.bklog) [user config only]
log_max_bytes Maximum job log size in bytes (0 disables limit) [user config only]

Examples:
# Set default output format to YAML
Expand All @@ -40,7 +42,10 @@ Examples:
$ bk config set pager "less -RS"

# Pin token storage to /dev/shm (recommended for headless Linux dev hosts)
$ bk config set credential_store shm`
$ bk config set credential_store shm

# Share log cache with the Buildkite MCP server (optional; empty uses ~/.bklog)
$ bk config set log_cache_url file://~/.bklog`
}

func (c *SetCmd) Run() error {
Expand Down
52 changes: 48 additions & 4 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ go 1.25.0
require (
github.com/alecthomas/kong v1.15.0
github.com/anmitsu/go-shlex v0.0.0-20200514113438-38f4b401e2be
github.com/buildkite/buildkite-logs v0.10.0
github.com/buildkite/go-buildkite/v5 v5.0.1
github.com/buildkite/termoji v0.0.0-20260330080310-c0aa4ebee0d1
github.com/charmbracelet/bubbles v1.0.0
Expand All @@ -26,31 +27,74 @@ require (
github.com/agnivade/levenshtein v1.2.1 // indirect
github.com/alexflint/go-arg v1.5.1 // indirect
github.com/alexflint/go-scalar v1.2.0 // indirect
github.com/andybalholm/brotli v1.2.1 // indirect
github.com/apache/arrow-go/v18 v18.6.0 // indirect
github.com/apache/thrift v0.23.0 // indirect
github.com/aws/aws-sdk-go-v2 v1.41.9 // indirect
github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream v1.7.11 // indirect
github.com/aws/aws-sdk-go-v2/config v1.32.20 // indirect
github.com/aws/aws-sdk-go-v2/credentials v1.19.19 // indirect
github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.18.25 // indirect
github.com/aws/aws-sdk-go-v2/feature/s3/transfermanager v0.2.3 // indirect
github.com/aws/aws-sdk-go-v2/internal/configsources v1.4.25 // indirect
github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.7.25 // indirect
github.com/aws/aws-sdk-go-v2/internal/v4a v1.4.26 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.13.10 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/checksum v1.9.18 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.13.25 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/s3shared v1.19.25 // indirect
github.com/aws/aws-sdk-go-v2/service/s3 v1.102.2 // indirect
github.com/aws/aws-sdk-go-v2/service/signin v1.1.1 // indirect
github.com/aws/aws-sdk-go-v2/service/sso v1.30.19 // indirect
github.com/aws/aws-sdk-go-v2/service/ssooidc v1.36.2 // indirect
github.com/aws/aws-sdk-go-v2/service/sts v1.42.3 // indirect
github.com/aws/smithy-go v1.26.0 // indirect
github.com/aymanbagabas/go-osc52/v2 v2.0.1 // indirect
github.com/bmatcuk/doublestar/v4 v4.6.1 // indirect
github.com/buildkite/go-buildkite/v5 v5.0.1 // indirect
github.com/cespare/xxhash/v2 v2.3.0 // indirect
github.com/charmbracelet/colorprofile v0.4.1 // indirect
github.com/charmbracelet/x/cellbuf v0.0.15 // indirect
github.com/charmbracelet/x/term v0.2.2 // indirect
github.com/clipperhouse/displaywidth v0.11.0 // indirect
github.com/clipperhouse/uax29/v2 v2.7.0 // indirect
github.com/danieljoos/wincred v1.2.3 // indirect
github.com/erikgeiser/coninput v0.0.0-20211004153227-1c3628e74d0f // indirect
github.com/goccy/go-json v0.10.5 // indirect
github.com/go-logr/logr v1.4.3 // indirect
github.com/go-logr/stdr v1.2.2 // indirect
github.com/goccy/go-json v0.10.6 // indirect
github.com/godbus/dbus/v5 v5.2.2 // indirect
github.com/google/flatbuffers v25.12.19+incompatible // indirect
github.com/google/wire v0.7.0 // indirect
github.com/googleapis/gax-go/v2 v2.22.0 // indirect
github.com/hashicorp/golang-lru/v2 v2.0.7 // indirect
github.com/klauspost/compress v1.18.6 // indirect
github.com/klauspost/cpuid/v2 v2.3.0 // indirect
github.com/kyokomi/emoji/v2 v2.2.13 // indirect
github.com/lucasb-eyer/go-colorful v1.4.0 // indirect
github.com/mattn/go-localereader v0.0.1 // indirect
github.com/muesli/ansi v0.0.0-20230316100256-276c6243b2f6 // indirect
github.com/muesli/cancelreader v0.2.2 // indirect
github.com/muesli/termenv v0.16.0 // indirect
github.com/pierrec/lz4/v4 v4.1.26 // indirect
github.com/rivo/uniseg v0.4.7 // indirect
github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f // indirect
github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415 // indirect
github.com/xo/terminfo v0.0.0-20220910002029-abceb7e1c41e // indirect
github.com/zeebo/xxh3 v1.1.0 // indirect
go.opentelemetry.io/auto/sdk v1.2.1 // indirect
go.opentelemetry.io/otel v1.43.0 // indirect
go.opentelemetry.io/otel/metric v1.43.0 // indirect
go.opentelemetry.io/otel/sdk v1.43.0 // indirect
go.opentelemetry.io/otel/sdk/metric v1.43.0 // indirect
go.opentelemetry.io/otel/trace v1.43.0 // indirect
gocloud.dev v0.46.0 // indirect
golang.org/x/exp v0.0.0-20260410095643-746e56fc9e2f // indirect
golang.org/x/sync v0.20.0 // indirect
golang.org/x/xerrors v0.0.0-20240903120638-7835f813f4da // indirect
google.golang.org/api v0.277.0 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20260427160629-7cedc36a6bc4 // indirect
google.golang.org/grpc v1.80.0 // indirect
google.golang.org/protobuf v1.36.11 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
)

Expand Down Expand Up @@ -78,11 +122,11 @@ require (
github.com/suessflorian/gqlfetch v0.7.0
github.com/xanzy/ssh-agent v0.3.3 // indirect
golang.org/x/crypto v0.50.0 // indirect
golang.org/x/mod v0.34.0 // indirect
golang.org/x/mod v0.35.0 // indirect
golang.org/x/net v0.53.0 // indirect
golang.org/x/sys v0.46.0 // indirect
golang.org/x/term v0.44.0
golang.org/x/text v0.36.0 // indirect
golang.org/x/tools v0.43.0 // indirect
golang.org/x/tools v0.44.0 // indirect
gopkg.in/warnings.v0 v0.1.2 // indirect
)
Loading