Skip to content

Commit b8589b3

Browse files
cwrauHeavyWombat
authored andcommitted
feat: add flag for useIndentLines
1 parent 56b69a3 commit b8589b3

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

internal/cmd/common.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ import (
3939

4040
type reportConfig struct {
4141
style string
42+
useIndentLines bool
4243
ignoreOrderChanges bool
4344
ignoreWhitespaceChanges bool
4445
kubernetesEntityDetection bool
@@ -60,6 +61,7 @@ type reportConfig struct {
6061

6162
var defaults = reportConfig{
6263
style: "human",
64+
useIndentLines: true,
6365
ignoreOrderChanges: false,
6466
ignoreWhitespaceChanges: false,
6567
kubernetesEntityDetection: true,
@@ -96,6 +98,7 @@ func applyReportOptionsFlags(cmd *cobra.Command) {
9698

9799
// Main output preferences
98100
cmd.Flags().StringVarP(&reportOptions.style, "output", "o", defaults.style, "specify the output style, supported styles: human, brief, github, gitlab, gitea")
101+
cmd.Flags().BoolVarP(&reportOptions.useIndentLines, "use-indent-lines", "u", defaults.useIndentLines, "use indent lines in the output")
99102
cmd.Flags().BoolVarP(&reportOptions.omitHeader, "omit-header", "b", defaults.omitHeader, "omit the dyff summary header")
100103
cmd.Flags().BoolVarP(&reportOptions.exitWithCode, "set-exit-code", "s", defaults.exitWithCode, "set program exit code, with 0 meaning no difference, 1 for differences detected, and 255 for program error")
101104

0 commit comments

Comments
 (0)