Skip to content

feat: add consistent JSON output across the CLI#185

Merged
rmanibus merged 2 commits into
mainfrom
cli-json-output
Apr 2, 2026
Merged

feat: add consistent JSON output across the CLI#185
rmanibus merged 2 commits into
mainfrom
cli-json-output

Conversation

@rmanibus
Copy link
Copy Markdown
Contributor

@rmanibus rmanibus commented Apr 2, 2026

Summary

  • add a shared global -json flag for CLI result output
  • emit structured JSON for operational commands instead of human summaries when requested
  • update command help, completion, tests, and the user guide to reflect the new behavior

Validation

  • env GOCACHE=/tmp/cloudstic-gocache GOMODCACHE=/tmp/cloudstic-gomodcache go test -count=1 ./cmd/cloudstic
  • env GOCACHE=/tmp/cloudstic-gocache GOMODCACHE=/tmp/cloudstic-gomodcache go test -count=1 ./internal/engine -run 'TestBackupManager_Run|TestFindPreviousSnapshot_'
  • env GOCACHE=/tmp/cloudstic-gocache GOMODCACHE=/tmp/cloudstic-gomodcache golangci-lint run ./...

Closes #187

@rmanibus rmanibus merged commit f1ecea6 into main Apr 2, 2026
11 of 12 checks passed
@rmanibus rmanibus deleted the cli-json-output branch April 2, 2026 12:09
@rmanibus rmanibus added this to the v1.14.0 milestone Apr 2, 2026
@rmanibus rmanibus added the enhancement New feature or request label Apr 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat: make JSON output consistent across the CLI

1 participant