mirror of
https://github.com/replicatedhq/troubleshoot.git
synced 2026-04-15 07:16:34 +00:00
Implemented support bundle diff command
This commit is contained in:
@@ -18,21 +18,38 @@ The output can be formatted as JSON for programmatic consumption or as
|
||||
human-readable text for manual review.
|
||||
|
||||
```
|
||||
support-bundle diff <old-bundle.tgz> <new-bundle.tgz> [flags]
|
||||
support-bundle diff <old-bundle.(tar.gz|tgz)> <new-bundle.(tar.gz|tgz)> [flags]
|
||||
```
|
||||
|
||||
### Options
|
||||
|
||||
```
|
||||
-h, --help help for diff
|
||||
--ignore-order ignore ordering differences in arrays and lists (default true)
|
||||
--ignore-paths strings file paths to ignore in diff (supports glob patterns)
|
||||
--ignore-timestamps ignore timestamp differences in logs and events (default true)
|
||||
--include-remediation include remediation suggestions in diff output (default true)
|
||||
--output string output format: text, json, html (default "text")
|
||||
-f, --output-file string write diff output to file instead of stdout
|
||||
--significance-threshold string minimum significance level to report: low, medium, high (default "medium")
|
||||
--verbose include detailed diff information
|
||||
--diff-context int number of context lines to include around changes in unified diffs (default 3)
|
||||
-h, --help help for diff
|
||||
--hide-inline-diffs hide inline unified diffs in the report
|
||||
--include-log-diffs include inline diffs for log files as well
|
||||
--max-diff-files int maximum number of files to include inline diffs for; additional modified files will omit inline diffs (default 50)
|
||||
--max-diff-lines int maximum total lines to include in an inline diff for a single file (default 200)
|
||||
-o, --output string file path of where to save the diff report (default prints to stdout)
|
||||
--format string output format; set to 'json' to emit machine-readable JSON to stdout or -o
|
||||
```
|
||||
|
||||
### Notes
|
||||
|
||||
- Only `.tar.gz` bundles are supported.
|
||||
- Inline diffs are generated for text files up to an internal size cap and for a limited number of files (configurable with `--max-diff-files`).
|
||||
|
||||
### Examples
|
||||
|
||||
```
|
||||
# Human-readable diff to stdout
|
||||
support-bundle diff old.tgz new.tgz
|
||||
|
||||
# JSON output to a file
|
||||
support-bundle diff old.tgz new.tgz --format=json -o diff.json
|
||||
|
||||
# Human-readable report with more context lines, written to a file
|
||||
support-bundle diff old.tgz new.tgz --diff-context=5 -o report.txt
|
||||
```
|
||||
|
||||
### Options inherited from parent commands
|
||||
@@ -43,7 +60,6 @@ support-bundle diff <old-bundle.tgz> <new-bundle.tgz> [flags]
|
||||
```
|
||||
|
||||
### SEE ALSO
|
||||
|
||||
* [support-bundle](support-bundle.md) - Generate a support bundle from a Kubernetes cluster or specified sources
|
||||
|
||||
###### Auto generated by spf13/cobra on 15-Sep-2025
|
||||
|
||||
Reference in New Issue
Block a user