We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1c05fd9 commit 2b962e9Copy full SHA for 2b962e9
1 file changed
diff/report.go
@@ -90,7 +90,9 @@ func printDyffReport(r *Report, to io.Writer) {
90
_ = os.Remove(newFile.Name())
91
}()
92
93
+ context := -1
94
for _, entry := range r.Entries {
95
+ context = entry.Context
96
_, _ = currentFile.WriteString("---\n")
97
_, _ = newFile.WriteString("---\n")
98
for _, record := range entry.Diffs {
@@ -116,6 +118,11 @@ func printDyffReport(r *Report, to io.Writer) {
116
118
OmitHeader: true,
117
119
MinorChangeThreshold: 0.1,
120
}
121
+
122
+ if context != -1 {
123
+ reportWriter.MultilineContextLines = context
124
+ }
125
126
_ = reportWriter.WriteReport(to)
127
128
0 commit comments